I am looking for a cross-database (SQLite, PostgreSQL, MySQL) method  
of extracting the time portion of a timestamp. I can't just use the  
"time()" function, because in PostgreSQL it needs to be in quotes (or  
preceded by pg_catalog.) to work, while in SQLite quoting the function  
returns an error. It was suggested that I use a cast(timestamp_column  
as time) function, but while this works in PosgreSQL, in SQLite it  
returns the year of the timestamp, not the time. Is there a way to  
make the cast function actually return the time in SQLite? Or perhaps  
some other way to extract the time of a timestamp that works in all  
three databases? Thanks.

-----------------------------------------------
Israel Brewster
Computer Support Technician II
Frontier Flying Service Inc.
5245 Airport Industrial Rd
Fairbanks, AK 99709
(907) 450-7250 x293
-----------------------------------------------



_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to