I have two columns IsHomeDelivery and Ispurchase whose values can be 0 and 1.
When value is 1 then i have to show text.
Means when ishomedelevery=1 then 'homedelivery ispurchase=1 then 'purchase'
i have formed following query:
SELECT
LocationName,
BranchName,
AddLine1,
AddLine2,
Tel1,
CASE
WHEN LocationType='CC' THEN 'Call Center'
WHEN LocationType='CL' THEN 'Operation'
END AS 'Location Type',
CASE
WHEN IsPurchase= 1 THEN 'Purchase'
WHEN IsHomeDelivery = 1 THEN 'Home Delivery'
WHEN IsPurchase=1 AND IsHomeDelivery=1 THEN 'Purchase And Home Delevery'
END AS 'Type'
FROM PescaLocation
but unfortunatly its not working for both columns true.
Means when isHomedelivery and isPurchase both are 1 then it is showing 'purchase' whereas it should show 'home delivery and purchase'
plz help me.