Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CASE syntax?

Status
Not open for further replies.

milton747

Programmer
Apr 21, 2005
133
US
I wrestling with the CASE statement below.
I want to set FLAGC based on credit rank and order total.
See anything odd? Thanks folks.



SELECT customers.creditrank, OrderTotals.OrderTotal,
CASE ( WHEN OrderTotals_OrderTotal > 1000000 AND customers_creditrank = 'A' THEN '1'
END) AS FLAGC
FROM customers, OrderTotals

 
JetSQL use IIf instead of CASE:
IIf(condtion, true value, false value)

The above is the translation of the below:
CASE WHEN condtion THEN true value ELSE false value END

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top