select Case When (DATENAME(dw, cm.Hearing_Date) as DayName) ='Tuesday'
Then 'मंगलवार' from xyz;
That should be:
select Case When DATENAME(dw, cm.Hearing_Date) ='Tuesday' Then 'मंगलवार' end as DayName
from xyz;
You need to fix your CASE syntax and might use the simple version (assuming you want to return other weekdays, too):
select
Case DATENAME(dw, cm.Hearing_Date)
When 'Monday' Then 'सोमवार' -- sometimes translate.google is helpful :-)
When 'Tuesday' Then 'मंगलवार'
...
end as DayName
from xyz;
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.