> I prefer using the PortableApps SQLite browser for other things as you
can have tabbed SQL queries but it doesn't have the DATETIME data type

Date and Time *Datatype*. *SQLite* does not have a storage *class* set
aside for storing dates and/or times. Instead, the built-in Date And Time
Functions of *SQLite *are capable of storing dates and times as TEXT, REAL,
or INTEGER values: TEXT as ISO8601 strings ("YYYY-MM-DD HH:MM:SS.SSS").

DB4S (DB Browser for SQLite - the 'real' name for SQLite Browser) will
accept anything as a data type, not necessarily whats in the drop down list.

Drop me an email - I can show you how to create an application in
SharpDevelop using VB.Net if you required.  What you want could be
accomplished with 'naked' SQLite, but a proper 'script' (or application)
would give you much more control, reporting, etc, etc.

PS: DB4S is on v3.10 now, so if you're using the 'portable version', it
needs updating! ;)


Thanks,
Chris


On Tue, Aug 22, 2017 at 9:32 AM, Matthew Halliday <fj1200...@gmail.com>
wrote:

> Hi Clemens - thanks for the reply.
>
> I'm trying to keep them a regular 4  or 6 hours - I'll see what works
> best.  The script runs as a scheduled task.
>
> I used the SQLite Studio to create the table so used the DATETIME data type
> for that, and although I used yyyy-mm-dd hh:mm:ss in the script it seems to
> have reverted it to dd/mm/yy hh:mm:ss.   I prefer using the PortableApps
> SQLite browser for other things as you can have tabbed SQL queries but it
> doesn't have the DATETIME data type.  if I use "where date_time =
> date('now','-1 day')"  for example, that seems to work ok.
>
> I have mailing list emails going back a few years to when I used to use
> SQLite a lot but couldn't find anything in them for this.
>
> On Tue, Aug 22, 2017 at 9:20 AM, Clemens Ladisch <clem...@ladisch.de>
> wrote:
>
> > Matthew Halliday wrote:
> > > I have a simple import table: id, servername, drive, capacity, used_mb,
> > > free_mb, free_pc (%) and a date_time field.
> >
> > What is the format of the values in the date_time field?
> >
> > Is there always a constant offset between two consecutive timestamps?
> >
> >
> > Regards,
> > Clemens
> > _______________________________________________
> > sqlite-users mailing list
> > sqlite-users@mailinglists.sqlite.org
> > http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
> >
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to