Skip Menu |

This queue is for tickets about the Catalyst-Plugin-AutoCRUD CPAN distribution.

Report information
The Basics
Id: 49261
Status: resolved
Priority: 0/
Queue: Catalyst-Plugin-AutoCRUD

People
Owner: OLIVER [...] cpan.org
Requestors: perl [...] rainboxx.de
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



Subject: C::P::AutoCRUD ignores "timestamp with time zone" (PostgreSQL)
When editing a column defined as "timestamp with time zone" in PostgreSQL (results in "2009-08-25 03:12:56.692842+02"), C::P::AutoCRUD ignores everything after the date and displays "2009-08-25" as date and "00:00:00" as time. Also it is not possible to edit the time part by hand: writing "03:12:56.692842+02", C::P::AutoCRUD displays an error. When saving it, "00-00-00" is written into database which is really fatal as it removes the time zone part and truncates the timestamp to seconds.
Hi, On Sun Aug 30 16:58:13 2009, MDIETRICH wrote: Show quoted text
> When editing a column defined as "timestamp with time zone" in > PostgreSQL (results in "2009-08-25 03:12:56.692842+02"), > C::P::AutoCRUD ignores everything after the date and displays > "2009-08-25" as date and "00:00:00" as time.
This is indeed a bug, and thanks for the report. What I think was tripping it up was the "float" format seconds (56.692842), because on my test system with PostgreSQL 8.1 it only returns integer seconds. I have patched the source to floor the seconds when they are read from the database (not ideal, I know). However there is another issue here with the time zone when you use "timestamp with time zone" - in your case the +02 will be completely lost! There is not much I can do about this right now, without quite a large update to the user interface to have a new widget for the UTC offset value. I will make it a wishlist item and hopefully find the time to look at it. Once again thanks for the report. I have released version 0.49 to CPAN which should work for you, at least, to display correctly in the UI. If you do not get this, please let me know and we can investigate as to why. -- regards, oliver.