I am a beginner and I use SQL Server and need help with converting date and time. How do I convert 2022-03-01 00:00:00.000 to yyyymmdd using Case when?
I tried this ,format(pol_eff_dt, ‘yyyymmdd’), but results are this: 20220001 and I was expecting 20220301
I appreciate any assistance that you can provide me.
Thank you!
New contributor
NVsquirrel is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.