Sanjiv
Sanjiv

Reputation: 1298

Query to Convert UTC datetime to GMT

Hi I have column having datetime in (2017-11-15 13:01:50.397). I want to convert this UTC datetime to GMT time format.

Is there any query to convert or what i have to add or subtract number so that it will show in GMT datetime format

Upvotes: 0

Views: 246

Answers (1)

Zaynul Abadin Tuhin
Zaynul Abadin Tuhin

Reputation: 31991

you can try below way

 declare @InputUtcDateTime datetime = '2017-11-15 13:01:50.397'

   select @InputUtcDateTime - getutcdate() + getdate()

Upvotes: 1

Related Questions