Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
IIF in a SQL Statement
Message
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00810425
Message ID:
00811090
Views:
14
You can use 1=1 as True and 1=2 as False.

>Thank you for your response.
>
>The problem I have is that when I evaluate the SQL Statement in VFP, before I send a SQLEXEC, the statement may look like this :
>
>Select * from table1 where .T. and .T. and Table1.Field1 = '191'
>or
>Select * from table1 where True and True and Table1.Field1 = '191'
>or
>Sselect * from table1 where 1 and 1 and Table1.Field1 = ' 191'
>
>.T. and True and 1 are not valid TRUE expression in Sql Server.
>I am looking at a valid TRUE expression in SQL Server.
>
>Waiting for comments...
>
>>SQL Server has a CASE - END structure which corresponds to FoxPro IIF().
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform