[ http://www.datanucleus.org/servlet/jira/browse/NUCRDBMS-272?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17143#action_17143 ]
Michael Brown commented on NUCRDBMS-272:
----------------------------------------
I think I may be on the cusp of understanding the problem, but more on that later when I unerstand more.
What concerns me is that I have a user seeing this problem, I can re-produce it in the SVN head of DN, but you don't experience it.
I'd like to compare our environments, just to get to the bottom of this.
I am testing on
Ubuntu 9.04 i686
Java 1.6.0_13
HSQL
I build using Maven2, using the script build_accessplatform_2_0.sh.
Are there any major differences with your test environment?
> Query by date when field mapped as varchar fails
> ------------------------------------------------
>
> Key: NUCRDBMS-272
> URL: http://www.datanucleus.org/servlet/jira/browse/NUCRDBMS-272
> Project: DataNucleus RDBMS
> Issue Type: Bug
> Components: Queries
> Affects Versions: 2.0.0.m2
> Environment: Win7, MySQL 5, Java 6
> Reporter: Michael Brown
> Attachments: date_tests.patch, date_tests2.patch
>
>
> Doing a query by date, where the date field is persisted as a varchar, fails to find the row. Looking at the logs I can see that values are inserted correctly, but it is searching in the wrong timezone, and formatting the date incorrectly. This leads me to believe that the query is not using the specified mapping to translate query parameters.
> I am attempting to investigate this right now, but what would really help are a few pointers in the right direction.
> A patch to the tests in SVN to demonstrate this issue will also be attached in a moment.
> Below I also attach logged sql statements, that demonstrate the mis-match.
> INSERT INTO g_pc_98mbjzp8_datecont (g_ia_sequence,g_ia_frozen,g_at_ovvtecif_date,g_at_2zj4at3w_identity,g_ia_version) VALUES (<2>,<false>,<'2009-08-09 14:17:01.000'>,<'9dc4f500-85bc-4fa2-a413-561b5759a60d'>,<1>)
> SELECT 'com.assethouse.goya.test.bugs.bug166.DateContainer' AS JPOXMETADATA,this.g_ia_version,this.g_at_ovvtecif_date,this.g_at_2zj4at3w_identity,this.g_ia_frozen,this.g_ia_sequence FROM g_pc_98mbjzp8_datecont this WHERE this.g_at_ovvtecif_date = <2009-08-09 15:17:01.0>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://www.datanucleus.org/servlet/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
|