HelpSpot Help Desk Software | HelpSpot Blog | HelpSpot Support

Date conversion


#1

I’m creating a SQL Server Analysis Cube for requests. I’d be grateful if you would let me jnow the algorithm to convert your GMTdate format to stanard SQL Server, please?


#2

Yes, the dateadd function does this in SQL Server.

dateadd(ss, {UNIX_timestamp}, ‘19700101’)

Here it is in a query:

SELECT xRequest, dtGMTOpened, dateadd(ss,dtGMTOpened,‘19700101’) AS opendate FROM HS_Request


#3

Thanks Ian - you’re a star! :slight_smile: