On 6 Jan 2015, at 6:13pm, MikeSnow <michael.sab...@gmail.com> wrote:
> I am trying to create a CASE statement that converts time zones to UTC for > db storage. > For example, I have 3 columns, ReceiveDate, Timezone, UTC Datetime. > 04/11/2014 2:00:00, EST, <empty> > > I would like to update UTC Datetime with logic based off "Timezone" col to > store as UTC? Write code which puts those three strings together into one string in a set format, then use SQLite DateTime functions to produce that timestamp as a number. <https://www.sqlite.org/lang_datefunc.html> Perhaps use format 2013-10-07 04:23:19.120-04:00 By the way, if possible, store a datetime as number instead of a string. That way you can do searching and sorting. Only when needed turn it back into a string date again, bearing in mind which timezone the user will find most convenient. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users