Hello All,

From: http://www.sqlite.org/cvstrac/wiki?p=DateAndTimeFunctions
"The julian day number is the preferred internal representation of
dates."

Unfortunately floating point values are not very readable when used
with existing GUI tools. The only problem is visualization, GUI tools
need to know which database columns are used for storing dates to
display them in a human readable form.

Actually Sqlite3Explorer http://www.singular.gr/sqlite/ solves this
problem as follows: it introduces 'DATE' datatype and for all columns
that have such type, the values are shown as dates (though it treats
dates in some delphi format, so they are not julian day compatible)

So you execute the following SQL statements:
CREATE TABLE test(information TEXT, last_update_time DATE);
INSERT INTO test VALUES("bla bla", julianday('now'));

And after that you see data from 'last_update_time' column as human
readable dates in GUI.

I liked this idea, and suggested it to SQliteSpy author (it is quite
convenient GUI tool and I started to use it), but he is unsure if it is
a good idea and a proper way of working with sqlite3 itself (if I
understood him correctly of course).

So this is a question to sqlite3 author: what do you think about that?
Is it a valid use of sqlite? Will this work the same for future versions
of sqlite?

Can we have some kind of common agreement for GUI tools so that dates
can be displayed and conveniently worked with?


Reply via email to