Showing posts with label iam. Show all posts
Showing posts with label iam. Show all posts

Wednesday, March 28, 2012

Problems in Creating Views in Sql

Hi everybody,
I have couple of Access databases needed to be
converted to access/Sql Client/Server database, which is new to me. I
am trying to convert my access quries to Sql Views or Stored
Procedures. I have run into a problem currently when creating view in
Sql:
I need to create some columns based on conditions of other columns,
for example:
1. Column example 1:
IIf([Column1]=-1,[ListPrice]*[Volume],IIf([Column2]=-1,0,[ListPrice]*Volume]))
2. Column example 2:
IIf(Len([Product].[P_No])<10,"",SUBSTRING([Product].[P_No],6,5))
3.Column example 3:
IIf([CustType]="D" ,([Field1]+[Field2])*[Volume],Field1*Vol
ume)
The above are actually the columns that I need to create.
I have these functions built in Access Queries, but not sure how to
build them in Sql views. Have tried different ways, but failed.
Any body knows how to do it?
Any help will be greatly appreciated!
Thanks in advance!"Shelley" <schow@.hersheys.com> wrote in message
news:e085e628.0402020838.450efcdc@.posting.google.com...
quote:

> 3.Column example 3:
> IIf([CustType]="D" ,([Field1]+[Field2])*[Volume],Field1*Vol
ume)

Take a look at the CASE statement in the online help.|||"Freddy" <noemail@.noemail> wrote in message news:<OT0rBBb6DHA.2524@.TK2MSFTNGP11.phx.gbl>...
quote:


> "Shelley" <schow@.hersheys.com> wrote in message
> news:e085e628.0402020838.450efcdc@.posting.google.com...
> Take a look at the CASE statement in the online help.

Thanks Freddy.
This one works.

Wednesday, March 21, 2012

Problems coneccting to BDE administrator

The sql server and bde administrator are in the same pc. I
am not in network when I want to get connecting althought
BDE it is not possible.What error do you get? Can you connect to the SQL Server from Query
Analyzer or OSQL (is BDE the only problem)?
To troubleshoot one of the more common errors, work through:
328306 INF: Potential Causes of the "SQL Server Does Not Exist or Access
http://support.microsoft.com/?id=328306
Cindy Gross, MCDBA, MCSE
http://cindygross.tripod.com
This posting is provided "AS IS" with no warranties, and confers no rights.

Saturday, February 25, 2012

problem with using linked server

:) hello everybody, i am using oracle as linked derver to my sql server db...when i write the query to access data from linked server(oracle) iam getting error like this...iam helpless..pls give ur ideas..
my query is: SELECT * FROM EOPI..EOP.CONTRACT
and the error is
OLE DB provider 'OraOLEDB.Oracle' reported an error.
[OLE/DB provider returned message: ORA-12638: Credential retrieval failed]..

thax and regards
kiran
senior software engineer :cool:When querying by linked server you have to use openquery.

SELECT * FROM OPENQUERY(linkedservername,'SELECT * FROM pubs')