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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IIF function not supported

Status
Not open for further replies.

mp9

Programmer
Sep 27, 2002
1,379
GB
Probably a stupid question...

I'm using a Transform Data Task to pump the results of a query out to an Excel spreadsheet. What I want to do is essentially this pseudocode:

If FieldA = -1 Then
Return TextStringA
Else If FieldB = -1 Then
Return TextStringB
Else
Return TextStringC

Now if I was using Access I'd use the IIF function in my query to do this but if seems the SQL in DTS doesn't support IIF. Is there are alternative I can use?

[pc2]
 
Thanks, I was thrown by the Query Designer not supporting CASE but of course the query returns the right stuff, which is all that matters.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top