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

select case

Status
Not open for further replies.

mayu03

Programmer
Oct 3, 2003
91
US
Why I am getting an error?
Status=
case Status when 'V' or 'E' then 'Voided'
else 'Active'end
 
Why I am getting an error?
Status=
case Status
when 'V' then 'Voided'
when 'E' then 'Voided'
else 'Active'
end

Status=
case when Status in ('V', 'E') then 'Voided'
else 'Active'end



======================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top