Quantcast
Channel: SQLServerCentral » SQL Server 2014 » Development - SQL Server 2014 » Latest topics
Viewing all articles
Browse latest Browse all 3145

SQL Function to convert date time to string

$
0
0
Hi Experts,please help me in writing a SQL Function as belowthe input parameter for function should be datetime of sql datetimeformatand out put should be a string = yyyymmdd1 or yyyymmdd2 the last character 1 or 2 based on below condition if time is between 6AM and 5.59PM then 1 if 6PM to 5.59AM then 2please help me with such function am running out of timethank you.Kishore

Viewing all articles
Browse latest Browse all 3145

Trending Articles