That would require some sort of active process or cron job. But that's
out of scope of SQLite. You will have to implement that on your own.
But if your EndDate is always "now", why having a true column at all? If
you do not want to take the current date from your environment, how
about something like this:
select *, datetime("now") as EndDate from mytable
No process, no cron job required. And your EndDate will always be "now".
Hi,
I have a column in a table where a value in a row is 'now'.
The 'now' value is in 'EndDate' column of that row.
I have also a trigger which fire up when in the 'EndDate' column a
Field was updated.
Because the 'now' value does changing every day in sense that every
one know that that yesterday's date is not equal with today's date I
am thinking about that that this could be used to fire up that trigger
automatically every day. But this does not work.
Then is there a mechanism which would update automatically such date
value - which is now the 'now' value in that 'EndDate' column Field
after a day passed?
This is needed in my application which calculates service time between
two dates, namely between StartDate and EndDate where EndDate has the
'now' value.
I hope I was clear what I mean.
--
Best, Pali
_______________________________________________
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