Here is what i tried select payment_date,((payment_date at time zone 'utc') at time zone 'ist') as. I am new to postgresql and i was wondering if there is a direct way to just convert the timestamp values in a table to a different timezone using a function. The docs are quite informative if you haven't seen them yet.
What i need to get from the procedure. I have a column of the timestamp without time zone type and would like to have that default to the current time in utc. String result = result_set.getstring (my_time);
When i query this column from my command line database client, it shows me the dates in utc, which is what i would expect. I am intending to do so as well, of course, but my current scenario is a database migration from sql server to postgresql (as part of a big application overhaul), where the. I need to convert local time to utc using a function. My guess is that your column type is timestamp [ (p) ] with time zone, and that npgsql automatically convert utc datetimes to local for such a column type.
I have a postgresql table with date field in the following format: For timestamp with time zone, the internally stored value is always in utc. Hi i am trying to convert utc datetime to ist time. Getting the current time in utc is easy:.