Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Convert Compound IIF To SQL Syntax
Message
De
01/07/2008 13:49:15
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Divers
Thread ID:
01327969
Message ID:
01327980
Vues:
11
BTW I just noticed you have an empty expression in between. It should error.
Cetin

>Thanks everyone!
>
>
>>>How do I do this in SQL?
>>>
>>>
>>>IIF(Trade.decTrade_Product_Balance <> 0 AND
>>>	(Trade.sTrade_Type_Pay_Rec = 'PAY' OR Trade.sTrade_Type_Pay_Rec AND Trade.sTran_Group_CD <> 'MAR'),
>>>		Transactions.decTrans_Amt, 0)
>>>
>>
>>
>>case
>>when Trade.decTrade_Product_Balance <> 0 AND
>>	(Trade.sTrade_Type_Pay_Rec = 'PAY' OR Trade.sTrade_Type_Pay_Rec AND Trade.sTran_Group_CD <> 'MAR') then
>>	Transactions.decTrans_Amt
>>else 0
>>end
>>
>>Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform