Discussion:
[bottlepy] sqlite3 and datetime issue, development mode
Victor Zambrano
2016-05-25 17:35:50 UTC
Permalink
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.

After running the bottle application, the same script just add this to the
record : 2016-05-25.

Is this something related to the localhost mode ?
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Luiz A. Menezes Filho
2016-05-25 17:39:36 UTC
Permalink
Victor,

It looks like the SQLite column type is *date* and not *datetime*. Have you
checked that?

Att,
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to the
record : 2016-05-25.
Is this something related to the localhost mode ?
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.
---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Victor Zambrano
2016-05-25 18:03:58 UTC
Permalink
El miércoles, 25 de mayo de 2016, 13:05:50 (UTC-4:30), Victor Zambrano
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to the
record : 2016-05-25.
Is this something related to the localhost mode ?
EDIT: the result from production server is the the same, sqlite is storing
the first time from datetime only.

El miércoles, 25 de mayo de 2016, 13:29:05 (UTC-4:30), Luiz Antonio de
Post by Victor Zambrano
Victor,
It looks like the SQLite column type is *date* and not *datetime*. Have
you checked that?
Att,
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to
the record : 2016-05-25.
Is this something related to the localhost mode ?
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.
---
You received this message because you are subscribed to the Google Groups
"bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Victor Zambrano
2016-05-25 18:05:38 UTC
Permalink
Thansk for your reply. I checked that, column type is DATETIME. I tested
inserting record outside the web environment, and the record is as
expected, a full DATETIME string.
The script under web environment, just add the first part.

El miércoles, 25 de mayo de 2016, 13:29:05 (UTC-4:30), Luiz Antonio de
Post by Luiz A. Menezes Filho
Victor,
It looks like the SQLite column type is *date* and not *datetime*. Have
you checked that?
Att,
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to
the record : 2016-05-25.
Is this something related to the localhost mode ?
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.
---
You received this message because you are subscribed to the Google Groups
"bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Victor Zambrano
2016-05-25 19:21:37 UTC
Permalink
*SOLVED !*


*Thank you for your attention*
El miércoles, 25 de mayo de 2016, 13:29:05 (UTC-4:30), Luiz Antonio de
Post by Luiz A. Menezes Filho
Victor,
It looks like the SQLite column type is *date* and not *datetime*. Have
you checked that?
Att,
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to
the record : 2016-05-25.
Is this something related to the localhost mode ?
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.
---
You received this message because you are subscribed to the Google Groups
"bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Victor Zambrano
2016-05-25 19:23:20 UTC
Permalink
*SOLVED ! *Made a silly mistake with my own variables for
datetime.today(). Thank you for your attention.

El miércoles, 25 de mayo de 2016, 13:29:05 (UTC-4:30), Luiz Antonio de
Post by Luiz A. Menezes Filho
Victor,
It looks like the SQLite column type is *date* and not *datetime*. Have
you checked that?
Att,
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to
the record : 2016-05-25.
Is this something related to the localhost mode ?
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.
---
You received this message because you are subscribed to the Google Groups
"bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Victor Zambrano
2016-05-25 18:01:30 UTC
Permalink
El miércoles, 25 de mayo de 2016, 13:05:50 (UTC-4:30), Victor Zambrano
Post by Victor Zambrano
I am trying to insert datetime object to sqlite table. Outside bottle
environment, the python script stores 2016-05-25 12:56:55.757977, as
expected.
After running the bottle application, the same script just add this to the
record : 2016-05-25.
Is this something related to the localhost mode ?
EDIT: the result from production server is the the same, sqlite is storing
the first time from datetime only.
--
--
You are member of the "bottlepy" group at google groups.
See http://groups.google.de/group/bottlepy for mailing list options.
See http://bottlepy.org/ for news and documentation.

---
You received this message because you are subscribed to the Google Groups "bottlepy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bottlepy+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...