Microsoft
Software
Hardware
Network
Question : Need help with CASE statement
I have read CASE syntax, but I am still confuse. I want to write a CASE base on targetID as follow:
targetID = 1
FabricToSend="1 yard"
targetID = 2
FabricToSend = "2 yard"
i have no clue on how to start. :(
can someone guide me?
thanks
Answer : Need help with CASE statement
SELECT FabricToSend = CASE (TargetID) when 1 then '1 yard' when 2 then '2 Yard' else null end
or
SELECT FabricToSend = = CAST (TargetID as varchar)+ ' yard'
Random Solutions
Microsoft Access 2007 Connection String
Sporadic Numeric field overflow
Best practice; Front end Access 2007 Application, updating Back end SQL 2005 DB
Using IEAK8 to deploy IE8 to client computers
Unable to change case in the last column of a table through VBA
MS Access query Find case sensitive matching records.
Problems when using static lib - MS VC++
SQL Server Dynamic Procedure Design
date is incompatible with int
Changing the IP address of a NT4 PDC