You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cayenne.apache.org by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org> on 2009/12/30 09:21:29 UTC

[jira] Created: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Wrong Types mapping for selected values in Row Queries
------------------------------------------------------

                 Key: CAY-1354
                 URL: https://issues.apache.org/jira/browse/CAY-1354
             Project: Cayenne
          Issue Type: Bug
          Components: Cayenne Core Library
    Affects Versions: 3.1M1
            Reporter: Evgeny Ryabitskiy
            Priority: Critical
         Attachments: ReturnTypesMappingTest.java

 By default every SQL type is mapped to some Java type by modeler.
I am expecting same behavior in common DataRow queries (without ORM).
But in fact half of types are not mapped correctly....

Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


RE: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Рябицкий Евгений <er...@diasoft.ru>.
Nope. But it helps... thx! :)

Evgeny.


-----Original Message-----
From: Tore Halset [mailto:halset@pvv.ntnu.no] 
Sent: Wednesday, January 13, 2010 10:21 AM
To: dev@cayenne.apache.org
Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

This is an old-timer. Did you do a "createlang plpgsql databasename"?

 - Tore.

On Jan 13, 2010, at 07:54 , Рябицкий Евгений wrote:

> 13.01.2010 9:52:17 org.apache.cayenne.unit.CayenneResources getResources
> SEVERE: Error generating schema...
> org.postgresql.util.PSQLException: ERROR: language "plpgsql" does not exist


Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Tore Halset <ha...@pvv.ntnu.no>.
This is an old-timer. Did you do a "createlang plpgsql databasename"?

 - Tore.

On Jan 13, 2010, at 07:54 , Рябицкий Евгений wrote:

> 13.01.2010 9:52:17 org.apache.cayenne.unit.CayenneResources getResources
> SEVERE: Error generating schema...
> org.postgresql.util.PSQLException: ERROR: language "plpgsql" does not exist


RE: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Рябицкий Евгений <er...@diasoft.ru>.
13.01.2010 9:52:17 org.apache.cayenne.unit.CayenneResources getResources
SEVERE: Error generating schema...
org.postgresql.util.PSQLException: ERROR: language "plpgsql" does not exist
	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1592)
	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1327)
	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:192)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:451)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:336)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:328)
	at org.apache.cayenne.unit.AccessStackAdapter.executeDDL(AccessStackAdapter.java:231)
	at org.apache.cayenne.unit.AccessStackAdapter.executeDDL(AccessStackAdapter.java:240)
	at org.apache.cayenne.unit.PostgresStackAdapter.createdTables(PostgresStackAdapter.java:68)
	at org.apache.cayenne.unit.AbstractAccessStack.createSchema(AbstractAccessStack.java:267)
	at org.apache.cayenne.unit.SimpleAccessStack.createSchema(SimpleAccessStack.java:121)
	at org.apache.cayenne.unit.CayenneResources.rebuildSchema(CayenneResources.java:192)
	at org.apache.cayenne.unit.CayenneResources.getResources(CayenneResources.java:108)
	at org.apache.cayenne.unit.CayenneCase.<init>(CayenneCase.java:66)
	at org.apache.cayenne.CayenneDataObjectValidationTest.<init>(CayenneDataObjectValidationTest.java:37)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
	at junit.framework.TestSuite.createTest(TestSuite.java:131)
	at junit.framework.TestSuite.addTestMethod(TestSuite.java:114)
	at junit.framework.TestSuite.<init>(TestSuite.java:75)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
	at org.apache.maven.surefire.junit.JUnitTestSet.constructTestObject(JUnitTestSet.java:151)
	at org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.java:197)
	at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:115)
	at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:102)
	at org.apache.maven.surefire.Surefire.run(Surefire.java:180)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:350)
	at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1021)
Tests run: 3, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 9.093 sec <<< FAILURE!

 



-----Original Message-----
From: Ольга Ткачева [mailto:tkachovaolga@gmail.com] 
Sent: Tuesday, January 12, 2010 7:43 PM
To: dev@cayenne.apache.org
Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Evgeny, give your error in postgres. I think this error while generating the
schema.


12 января 2010 г. 16:50 пользователь Рябицкий Евгений <
eryabitskiy@diasoft.ru> написал:

>
> I run tests without my patch over hsqldb, mssql + jtds, posgres
>
> Postgres don't like me.... :/
>
>
> NO PATCH (ONLY TEST)
>
> * hsqldb *
>
>  Failed tests:
>   testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 7, Errors: 4, Skipped: 0
>
>
> * SQL Server + JTDS *
>
> Failed tests:
>   testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
>   testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
>   testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testTIMESTAMP2(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)
>   testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 17, Errors: 5, Skipped: 0
>
>
> * postgres *
>
> Failed tests:
>  warning(junit.framework.TestSuite$1)
>   testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>   testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>   testMultiDBUpdate(org.apache.cayenne.access.DataContextCrossDBTest)
>  testQualifyOnToMany(org.apache.cayenne.unit.jira.CAY_194Test)
>  testQualifyOnToOne(org.apache.cayenne.unit.jira.CAY_194Test)
>  testUnregisterThenRegister(org.apache.cayenne.access.ObjectStoreTest)
>  testNullifyToOne(org.apache.cayenne.NestedCayenneContextTest)
>  testSelect(org.apache.cayenne.NestedCayenneContextTest)
>  testDeleteNew(org.apache.cayenne.NestedCayenneContextTest)
>  testLocalObjectSynchronize(org.apache.cayenne.NestedCayenneContextTest)
>  testLocalObjectsNoOverride(org.apache.cayenne.NestedCayenneContextTest)
>  testPrefetchingToOne(org.apache.cayenne.NestedCayenneContextTest)
>  testPrefetchingToMany(org.apache.cayenne.NestedCayenneContextTest)
>  testCommitChangesToParent(org.apache.cayenne.NestedCayenneContextTest)
>
>  testCommitChangesToParentDeleted(org.apache.cayenne.NestedCayenneContextTest)
>  testCommitChanges(org.apache.cayenne.NestedCayenneContextTest)
>  testAddRemove(org.apache.cayenne.NestedCayenneContextTest)
>  testChangeRel(org.apache.cayenne.NestedCayenneContextTest)
>  testCAY1183(org.apache.cayenne.NestedCayenneContextTest)
>
>  testRollbackRelationshipModification(org.apache.cayenne.remote.RemoteRollbackTest)
>  testRollbackDeletedObject(org.apache.cayenne.remote.RemoteRollbackTest)
>  testRollbackModifiedObject(org.apache.cayenne.remote.RemoteRollbackTest)
>  testInsertSubclass(org.apache.cayenne.CayenneContextInheritanceTest)
>
>  testDeepMergeExistingSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
>
>  testDeepMergeNonExistentSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
>  testPrefetchQuote(org.apache.cayenne.access.DataContexQuoteTest)
>
>  testParentUpdatedId(org.apache.cayenne.remote.NestedObjectContextParentEventsTest)
>  testSave(org.apache.cayenne.access.InheritanceTest)
>  testInsertSingle(org.apache.cayenne.GenericMappingTest)
>  testInsertRelated(org.apache.cayenne.GenericMappingTest)
>  testUpdateRelated(org.apache.cayenne.GenericMappingTest)
>
>  testReturnDiffInPrePersist(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>
>  testReturnDiffClientArcChanges(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>  testReturnIdDiff(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>  testNullify(org.apache.cayenne.remote.RelationshipChangeTest)
>  testChange(org.apache.cayenne.remote.RelationshipChangeTest)
>  testFailLockingOnToOne(org.apache.cayenne.access.OptimisticLockingTest)
>   testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
>   testAddToMany(org.apache.cayenne.CDOMapRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOMapRelationshipTest)
>  testInsert(org.apache.cayenne.access.EmbeddingTest)
>  testAddToMany(org.apache.cayenne.CayenneContextMapRelationshipTest)
>  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)
>   testNullifyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testCascadeToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testDenyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>
>  testCascadeToOneNewObject(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testDenyToOne(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionToOne(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionToMany(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testCascadeFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testCascadeFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testNullifyFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testNullifyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testDenyFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testDenyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testUpdate(org.apache.cayenne.access.jdbc.SoftDeleteBatchQueryBuilderTest)
>
>  testPeerObjectUpdatedSimpleProperty(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedToOneRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedToManyRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedTempOID(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testMultipleSimpleProperties(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
>
>  testComplimentaryArcs(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
>  testDeletion(org.apache.cayenne.remote.CayenneContextDeletionTest)
>  testOutParams(org.apache.cayenne.access.DataContextProcedureQueryTest)
>  testValidate(org.apache.cayenne.CayenneContextValidationTest)
>
>  testReturnDiffInPrePersist(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffInPreUpdate(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffClientArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffServerArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
>  testReadRelationship(org.apache.cayenne.CDOOneToManyFKTest)
>  testAddToMany(org.apache.cayenne.CDOSetRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOSetRelationshipTest)
>  testDefault(org.apache.cayenne.remote.RemoteCallbacksTest)
>  testServer(org.apache.cayenne.remote.LightSuperClassTest)
>
>  testCollectionMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>
>  testCollectionNotMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>
>  testCollectionNotMemberOfToOne(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>  testInsertJoinWithPK(org.apache.cayenne.FlattenedRelationshipsTest)
>
>  testQualifyOnToManyFlattened(org.apache.cayenne.FlattenedRelationshipsTest)
>  testToOneSeriesFlattenedRel(org.apache.cayenne.FlattenedRelationshipsTest)
>  testSynchronizeCommit(org.apache.cayenne.access.ClientServerChannelTest)
>  testRollbackChanges(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testSelectPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testCommitChangesPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testPostAddCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testPostAddOnObjectCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testPreRemoveCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testCAY830(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testOIDQueryInterception(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testAddToMany(org.apache.cayenne.CDOCollectionRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOCollectionRelationshipTest)
>  testDelete(org.apache.cayenne.CDOOneToOneFKTest)
>  testReadRelationship(org.apache.cayenne.CDOOneToOneFKTest)
>  testNewAdd(org.apache.cayenne.CDOOneToOneFKTest)
>  test2Null(org.apache.cayenne.CDOOneToOneFKTest)
>  testTakeObjectSnapshotDependentFault(org.apache.cayenne.CDOOneToOneFKTest)
>  testReplaceNull1(org.apache.cayenne.CDOOneToOneFKTest)
>  testReplaceNull2(org.apache.cayenne.CDOOneToOneFKTest)
>
>  testSyncNewObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncNewDeletedObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncNewObjectIntoDirtyContext(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncToManyRelationship(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncManyToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>   testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 23, Errors: 108, Skipped: 0
>
>
> Evgeny.
>
>
> -----Original Message-----
> From: Ольга Ткачева [mailto:tkachovaolga@gmail.com]
> Sent: Tuesday, January 12, 2010 4:43 PM
> To: dev@cayenne.apache.org
> Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected
> values in Row Queries
>
> in oracle ReturnTypesMappingTest has error generating schema
>
> SEVERE: Error generating schema...
> java.sql.SQLException: ORA-01754: a table may contain only one column of
> type LONG
>
>    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
>    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
>    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
>    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
>    at
> oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)
>
> in test generate 2 long column: LONGVARBINARY_COLUMN LONG RAW NULL,
> LONGVARCHAR_COLUMN LONG VARCHAR NULL
>
>
> 12 января 2010 г. 11:48 пользователь Andrus Adamchik <
> andrus@objectstyle.org
> > написал:
>
> >
> > On Jan 11, 2010, at 1:45 PM, Рябицкий Евгений wrote:
> >
> >  Strange result... looks like I have to install Postgress to check it
> >> myself... :)
> >>
> >> Evgeny.
> >>
> >
> > Hi Evgeny,
> >
> > looking at most test failures in Olga's tests, I see that most failures
> are
> > caused by various DB incompatibilities, and have nothing to do with the
> > change itself, but rather with the unit tests themselves not being
> > compatible with a given DB. Olga just logged one issue (CAY-1363) that is
> > actually a bug in Cayenne. Others are similar, such as:
> >
> > * MySQL truncating milliseconds (so the test has to be written to compare
> > with precision up to the nearest second)
> > * Precision and scale not declared for decimal values, causing loss of
> > precision in some DB's
> > * Max length for VARCHAR being 255 on some DBs
> >
> > Those fairly benign issues would cause massive test failures, and
> > potentially hide the real issues. And those affect not only the current
> > patch, but also your earlier commit per
> > http://svn.apache.org/viewvc?view=revision&revision=889168
> >
> > We may need your help to make your tests compatible with other DB's. Olga
> > is about to send a patch on top of your patch fixing some of the above
> > things (and also fix CAY-1363). Can you take it from there and install at
> > least PostgreSQL and MySQL and try to make your tests run on those (in
> > addition to Oracle, HSQLDB, and anything else you might be testing
> against)?
> >
> > This would be of tremendous help to us, as your changes touch on JDBC
> > internals that are very sensitive to DB and driver type and version.
> >
> > Andrus
> >
> >
> >
> >
>
>
> --
> Olga Tkacheva
>



-- 
Olga Tkacheva

RE: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Рябицкий Евгений <er...@diasoft.ru>.
org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "artist_pkey"
	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1592)
	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1327)
	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:192)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:451)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:350)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:343)
	at org.apache.cayenne.access.jdbc.SQLTemplateAction.execute(SQLTemplateAction.java:149)
	at org.apache.cayenne.access.jdbc.SQLTemplateAction.performAction(SQLTemplateAction.java:123)
	at org.apache.cayenne.access.DataNodeQueryAction.runQuery(DataNodeQueryAction.java:87)
	at org.apache.cayenne.access.DataNode.performQueries(DataNode.java:269)
	at org.apache.cayenne.access.DataDomainQueryAction.runQuery(DataDomainQueryAction.java:418)
	at org.apache.cayenne.access.DataDomainQueryAction.access$000(DataDomainQueryAction.java:65)
	at org.apache.cayenne.access.DataDomainQueryAction$2.transform(DataDomainQueryAction.java:391)
	at org.apache.cayenne.access.DataDomain.runInTransaction(DataDomain.java:847)
	at org.apache.cayenne.access.DataDomainQueryAction.runQueryInTransaction(DataDomainQueryAction.java:388)
	at org.apache.cayenne.access.UnitTestDomainQueryAction.runQueryInTransaction(UnitTestDomainQueryAction.java:54)
	at org.apache.cayenne.access.DataDomainQueryAction.execute(DataDomainQueryAction.java:117)
	at org.apache.cayenne.access.UnitTestDomainQueryAction.execute(UnitTestDomainQueryAction.java:48)
	at org.apache.cayenne.access.UnitTestDomain.onQuery(UnitTestDomain.java:63)
	at org.apache.cayenne.unit.SimpleAccessStack.createTestData(SimpleAccessStack.java:97)
	at org.apache.cayenne.unit.CayenneCase.createTestData(CayenneCase.java:119)
	at org.apache.cayenne.access.DataContextEJBQLQueryTest.testSelectFromWhereGreaterOrEqual(DataContextEJBQLQueryTest.java:314)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at junit.framework.TestCase.runTest(TestCase.java:154)
	at junit.framework.TestCase.runBare(TestCase.java:127)
	at junit.framework.TestResult$1.protect(TestResult.java:106)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.framework.TestResult.run(TestResult.java:109)
	at junit.framework.TestCase.run(TestCase.java:118)
	at junit.framework.TestSuite.runTest(TestSuite.java:208)
	at junit.framework.TestSuite.run(TestSuite.java:203)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.java:213)
	at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:115)
	at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:102)
	at org.apache.maven.surefire.Surefire.run(Surefire.java:180)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:350)
	at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1021)

 


-----Original Message-----
From: Ольга Ткачева [mailto:tkachovaolga@gmail.com] 
Sent: Tuesday, January 12, 2010 7:43 PM
To: dev@cayenne.apache.org
Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Evgeny, give your error in postgres. I think this error while generating the
schema.


12 января 2010 г. 16:50 пользователь Рябицкий Евгений <
eryabitskiy@diasoft.ru> написал:

>
> I run tests without my patch over hsqldb, mssql + jtds, posgres
>
> Postgres don't like me.... :/
>
>
> NO PATCH (ONLY TEST)
>
> * hsqldb *
>
>  Failed tests:
>   testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 7, Errors: 4, Skipped: 0
>
>
> * SQL Server + JTDS *
>
> Failed tests:
>   testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
>   testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
>   testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testTIMESTAMP2(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)
>   testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 17, Errors: 5, Skipped: 0
>
>
> * postgres *
>
> Failed tests:
>  warning(junit.framework.TestSuite$1)
>   testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>   testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>   testMultiDBUpdate(org.apache.cayenne.access.DataContextCrossDBTest)
>  testQualifyOnToMany(org.apache.cayenne.unit.jira.CAY_194Test)
>  testQualifyOnToOne(org.apache.cayenne.unit.jira.CAY_194Test)
>  testUnregisterThenRegister(org.apache.cayenne.access.ObjectStoreTest)
>  testNullifyToOne(org.apache.cayenne.NestedCayenneContextTest)
>  testSelect(org.apache.cayenne.NestedCayenneContextTest)
>  testDeleteNew(org.apache.cayenne.NestedCayenneContextTest)
>  testLocalObjectSynchronize(org.apache.cayenne.NestedCayenneContextTest)
>  testLocalObjectsNoOverride(org.apache.cayenne.NestedCayenneContextTest)
>  testPrefetchingToOne(org.apache.cayenne.NestedCayenneContextTest)
>  testPrefetchingToMany(org.apache.cayenne.NestedCayenneContextTest)
>  testCommitChangesToParent(org.apache.cayenne.NestedCayenneContextTest)
>
>  testCommitChangesToParentDeleted(org.apache.cayenne.NestedCayenneContextTest)
>  testCommitChanges(org.apache.cayenne.NestedCayenneContextTest)
>  testAddRemove(org.apache.cayenne.NestedCayenneContextTest)
>  testChangeRel(org.apache.cayenne.NestedCayenneContextTest)
>  testCAY1183(org.apache.cayenne.NestedCayenneContextTest)
>
>  testRollbackRelationshipModification(org.apache.cayenne.remote.RemoteRollbackTest)
>  testRollbackDeletedObject(org.apache.cayenne.remote.RemoteRollbackTest)
>  testRollbackModifiedObject(org.apache.cayenne.remote.RemoteRollbackTest)
>  testInsertSubclass(org.apache.cayenne.CayenneContextInheritanceTest)
>
>  testDeepMergeExistingSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
>
>  testDeepMergeNonExistentSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
>  testPrefetchQuote(org.apache.cayenne.access.DataContexQuoteTest)
>
>  testParentUpdatedId(org.apache.cayenne.remote.NestedObjectContextParentEventsTest)
>  testSave(org.apache.cayenne.access.InheritanceTest)
>  testInsertSingle(org.apache.cayenne.GenericMappingTest)
>  testInsertRelated(org.apache.cayenne.GenericMappingTest)
>  testUpdateRelated(org.apache.cayenne.GenericMappingTest)
>
>  testReturnDiffInPrePersist(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>
>  testReturnDiffClientArcChanges(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>  testReturnIdDiff(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>  testNullify(org.apache.cayenne.remote.RelationshipChangeTest)
>  testChange(org.apache.cayenne.remote.RelationshipChangeTest)
>  testFailLockingOnToOne(org.apache.cayenne.access.OptimisticLockingTest)
>   testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
>   testAddToMany(org.apache.cayenne.CDOMapRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOMapRelationshipTest)
>  testInsert(org.apache.cayenne.access.EmbeddingTest)
>  testAddToMany(org.apache.cayenne.CayenneContextMapRelationshipTest)
>  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)
>   testNullifyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testCascadeToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testDenyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>
>  testCascadeToOneNewObject(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testDenyToOne(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionToOne(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionToMany(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testCascadeFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testCascadeFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testNullifyFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testNullifyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testDenyFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testDenyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testUpdate(org.apache.cayenne.access.jdbc.SoftDeleteBatchQueryBuilderTest)
>
>  testPeerObjectUpdatedSimpleProperty(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedToOneRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedToManyRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedTempOID(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testMultipleSimpleProperties(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
>
>  testComplimentaryArcs(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
>  testDeletion(org.apache.cayenne.remote.CayenneContextDeletionTest)
>  testOutParams(org.apache.cayenne.access.DataContextProcedureQueryTest)
>  testValidate(org.apache.cayenne.CayenneContextValidationTest)
>
>  testReturnDiffInPrePersist(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffInPreUpdate(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffClientArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffServerArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
>  testReadRelationship(org.apache.cayenne.CDOOneToManyFKTest)
>  testAddToMany(org.apache.cayenne.CDOSetRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOSetRelationshipTest)
>  testDefault(org.apache.cayenne.remote.RemoteCallbacksTest)
>  testServer(org.apache.cayenne.remote.LightSuperClassTest)
>
>  testCollectionMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>
>  testCollectionNotMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>
>  testCollectionNotMemberOfToOne(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>  testInsertJoinWithPK(org.apache.cayenne.FlattenedRelationshipsTest)
>
>  testQualifyOnToManyFlattened(org.apache.cayenne.FlattenedRelationshipsTest)
>  testToOneSeriesFlattenedRel(org.apache.cayenne.FlattenedRelationshipsTest)
>  testSynchronizeCommit(org.apache.cayenne.access.ClientServerChannelTest)
>  testRollbackChanges(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testSelectPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testCommitChangesPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testPostAddCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testPostAddOnObjectCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testPreRemoveCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testCAY830(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testOIDQueryInterception(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testAddToMany(org.apache.cayenne.CDOCollectionRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOCollectionRelationshipTest)
>  testDelete(org.apache.cayenne.CDOOneToOneFKTest)
>  testReadRelationship(org.apache.cayenne.CDOOneToOneFKTest)
>  testNewAdd(org.apache.cayenne.CDOOneToOneFKTest)
>  test2Null(org.apache.cayenne.CDOOneToOneFKTest)
>  testTakeObjectSnapshotDependentFault(org.apache.cayenne.CDOOneToOneFKTest)
>  testReplaceNull1(org.apache.cayenne.CDOOneToOneFKTest)
>  testReplaceNull2(org.apache.cayenne.CDOOneToOneFKTest)
>
>  testSyncNewObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncNewDeletedObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncNewObjectIntoDirtyContext(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncToManyRelationship(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncManyToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>   testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 23, Errors: 108, Skipped: 0
>
>
> Evgeny.
>
>
> -----Original Message-----
> From: Ольга Ткачева [mailto:tkachovaolga@gmail.com]
> Sent: Tuesday, January 12, 2010 4:43 PM
> To: dev@cayenne.apache.org
> Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected
> values in Row Queries
>
> in oracle ReturnTypesMappingTest has error generating schema
>
> SEVERE: Error generating schema...
> java.sql.SQLException: ORA-01754: a table may contain only one column of
> type LONG
>
>    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
>    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
>    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
>    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
>    at
> oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)
>
> in test generate 2 long column: LONGVARBINARY_COLUMN LONG RAW NULL,
> LONGVARCHAR_COLUMN LONG VARCHAR NULL
>
>
> 12 января 2010 г. 11:48 пользователь Andrus Adamchik <
> andrus@objectstyle.org
> > написал:
>
> >
> > On Jan 11, 2010, at 1:45 PM, Рябицкий Евгений wrote:
> >
> >  Strange result... looks like I have to install Postgress to check it
> >> myself... :)
> >>
> >> Evgeny.
> >>
> >
> > Hi Evgeny,
> >
> > looking at most test failures in Olga's tests, I see that most failures
> are
> > caused by various DB incompatibilities, and have nothing to do with the
> > change itself, but rather with the unit tests themselves not being
> > compatible with a given DB. Olga just logged one issue (CAY-1363) that is
> > actually a bug in Cayenne. Others are similar, such as:
> >
> > * MySQL truncating milliseconds (so the test has to be written to compare
> > with precision up to the nearest second)
> > * Precision and scale not declared for decimal values, causing loss of
> > precision in some DB's
> > * Max length for VARCHAR being 255 on some DBs
> >
> > Those fairly benign issues would cause massive test failures, and
> > potentially hide the real issues. And those affect not only the current
> > patch, but also your earlier commit per
> > http://svn.apache.org/viewvc?view=revision&revision=889168
> >
> > We may need your help to make your tests compatible with other DB's. Olga
> > is about to send a patch on top of your patch fixing some of the above
> > things (and also fix CAY-1363). Can you take it from there and install at
> > least PostgreSQL and MySQL and try to make your tests run on those (in
> > addition to Oracle, HSQLDB, and anything else you might be testing
> against)?
> >
> > This would be of tremendous help to us, as your changes touch on JDBC
> > internals that are very sensitive to DB and driver type and version.
> >
> > Andrus
> >
> >
> >
> >
>
>
> --
> Olga Tkacheva
>



-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Ольга Ткачева <tk...@gmail.com>.
Evgeny, give your error in postgres. I think this error while generating the
schema.


12 января 2010 г. 16:50 пользователь Рябицкий Евгений <
eryabitskiy@diasoft.ru> написал:

>
> I run tests without my patch over hsqldb, mssql + jtds, posgres
>
> Postgres don't like me.... :/
>
>
> NO PATCH (ONLY TEST)
>
> * hsqldb *
>
>  Failed tests:
>   testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 7, Errors: 4, Skipped: 0
>
>
> * SQL Server + JTDS *
>
> Failed tests:
>   testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
>   testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
>   testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testTIMESTAMP2(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)
>   testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 17, Errors: 5, Skipped: 0
>
>
> * postgres *
>
> Failed tests:
>  warning(junit.framework.TestSuite$1)
>   testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>   testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>   testMultiDBUpdate(org.apache.cayenne.access.DataContextCrossDBTest)
>  testQualifyOnToMany(org.apache.cayenne.unit.jira.CAY_194Test)
>  testQualifyOnToOne(org.apache.cayenne.unit.jira.CAY_194Test)
>  testUnregisterThenRegister(org.apache.cayenne.access.ObjectStoreTest)
>  testNullifyToOne(org.apache.cayenne.NestedCayenneContextTest)
>  testSelect(org.apache.cayenne.NestedCayenneContextTest)
>  testDeleteNew(org.apache.cayenne.NestedCayenneContextTest)
>  testLocalObjectSynchronize(org.apache.cayenne.NestedCayenneContextTest)
>  testLocalObjectsNoOverride(org.apache.cayenne.NestedCayenneContextTest)
>  testPrefetchingToOne(org.apache.cayenne.NestedCayenneContextTest)
>  testPrefetchingToMany(org.apache.cayenne.NestedCayenneContextTest)
>  testCommitChangesToParent(org.apache.cayenne.NestedCayenneContextTest)
>
>  testCommitChangesToParentDeleted(org.apache.cayenne.NestedCayenneContextTest)
>  testCommitChanges(org.apache.cayenne.NestedCayenneContextTest)
>  testAddRemove(org.apache.cayenne.NestedCayenneContextTest)
>  testChangeRel(org.apache.cayenne.NestedCayenneContextTest)
>  testCAY1183(org.apache.cayenne.NestedCayenneContextTest)
>
>  testRollbackRelationshipModification(org.apache.cayenne.remote.RemoteRollbackTest)
>  testRollbackDeletedObject(org.apache.cayenne.remote.RemoteRollbackTest)
>  testRollbackModifiedObject(org.apache.cayenne.remote.RemoteRollbackTest)
>  testInsertSubclass(org.apache.cayenne.CayenneContextInheritanceTest)
>
>  testDeepMergeExistingSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
>
>  testDeepMergeNonExistentSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
>  testPrefetchQuote(org.apache.cayenne.access.DataContexQuoteTest)
>
>  testParentUpdatedId(org.apache.cayenne.remote.NestedObjectContextParentEventsTest)
>  testSave(org.apache.cayenne.access.InheritanceTest)
>  testInsertSingle(org.apache.cayenne.GenericMappingTest)
>  testInsertRelated(org.apache.cayenne.GenericMappingTest)
>  testUpdateRelated(org.apache.cayenne.GenericMappingTest)
>
>  testReturnDiffInPrePersist(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>
>  testReturnDiffClientArcChanges(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>  testReturnIdDiff(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
>  testNullify(org.apache.cayenne.remote.RelationshipChangeTest)
>  testChange(org.apache.cayenne.remote.RelationshipChangeTest)
>  testFailLockingOnToOne(org.apache.cayenne.access.OptimisticLockingTest)
>   testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
>   testAddToMany(org.apache.cayenne.CDOMapRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOMapRelationshipTest)
>  testInsert(org.apache.cayenne.access.EmbeddingTest)
>  testAddToMany(org.apache.cayenne.CayenneContextMapRelationshipTest)
>  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)
>   testNullifyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testCascadeToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testDenyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
>
>  testCascadeToOneNewObject(org.apache.cayenne.CayenneContextDeleteRulesTest)
>  testDenyToOne(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionToOne(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionToMany(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testNoActionFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testCascadeFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testCascadeFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testNullifyFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testNullifyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testDenyFlattened(org.apache.cayenne.access.DeleteRulesTest)
>  testDenyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
>  testUpdate(org.apache.cayenne.access.jdbc.SoftDeleteBatchQueryBuilderTest)
>
>  testPeerObjectUpdatedSimpleProperty(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedToOneRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedToManyRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testPeerObjectUpdatedTempOID(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
>
>  testMultipleSimpleProperties(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
>
>  testComplimentaryArcs(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
>  testDeletion(org.apache.cayenne.remote.CayenneContextDeletionTest)
>  testOutParams(org.apache.cayenne.access.DataContextProcedureQueryTest)
>  testValidate(org.apache.cayenne.CayenneContextValidationTest)
>
>  testReturnDiffInPrePersist(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffInPreUpdate(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffClientArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
>
>  testReturnDiffServerArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
>  testReadRelationship(org.apache.cayenne.CDOOneToManyFKTest)
>  testAddToMany(org.apache.cayenne.CDOSetRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOSetRelationshipTest)
>  testDefault(org.apache.cayenne.remote.RemoteCallbacksTest)
>  testServer(org.apache.cayenne.remote.LightSuperClassTest)
>
>  testCollectionMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>
>  testCollectionNotMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>
>  testCollectionNotMemberOfToOne(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
>  testInsertJoinWithPK(org.apache.cayenne.FlattenedRelationshipsTest)
>
>  testQualifyOnToManyFlattened(org.apache.cayenne.FlattenedRelationshipsTest)
>  testToOneSeriesFlattenedRel(org.apache.cayenne.FlattenedRelationshipsTest)
>  testSynchronizeCommit(org.apache.cayenne.access.ClientServerChannelTest)
>  testRollbackChanges(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testSelectPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testCommitChangesPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testPostAddCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testPostAddOnObjectCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testPreRemoveCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testCAY830(org.apache.cayenne.CayenneContextWithDataContextTest)
>
>  testOIDQueryInterception(org.apache.cayenne.CayenneContextWithDataContextTest)
>  testAddToMany(org.apache.cayenne.CDOCollectionRelationshipTest)
>  testAddToManyViaReverse(org.apache.cayenne.CDOCollectionRelationshipTest)
>  testDelete(org.apache.cayenne.CDOOneToOneFKTest)
>  testReadRelationship(org.apache.cayenne.CDOOneToOneFKTest)
>  testNewAdd(org.apache.cayenne.CDOOneToOneFKTest)
>  test2Null(org.apache.cayenne.CDOOneToOneFKTest)
>  testTakeObjectSnapshotDependentFault(org.apache.cayenne.CDOOneToOneFKTest)
>  testReplaceNull1(org.apache.cayenne.CDOOneToOneFKTest)
>  testReplaceNull2(org.apache.cayenne.CDOOneToOneFKTest)
>
>  testSyncNewObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncNewDeletedObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncNewObjectIntoDirtyContext(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncToManyRelationship(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>
>  testSyncManyToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
>   testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>   testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2031, Failures: 23, Errors: 108, Skipped: 0
>
>
> Evgeny.
>
>
> -----Original Message-----
> From: Ольга Ткачева [mailto:tkachovaolga@gmail.com]
> Sent: Tuesday, January 12, 2010 4:43 PM
> To: dev@cayenne.apache.org
> Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected
> values in Row Queries
>
> in oracle ReturnTypesMappingTest has error generating schema
>
> SEVERE: Error generating schema...
> java.sql.SQLException: ORA-01754: a table may contain only one column of
> type LONG
>
>    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
>    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
>    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
>    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
>    at
> oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)
>
> in test generate 2 long column: LONGVARBINARY_COLUMN LONG RAW NULL,
> LONGVARCHAR_COLUMN LONG VARCHAR NULL
>
>
> 12 января 2010 г. 11:48 пользователь Andrus Adamchik <
> andrus@objectstyle.org
> > написал:
>
> >
> > On Jan 11, 2010, at 1:45 PM, Рябицкий Евгений wrote:
> >
> >  Strange result... looks like I have to install Postgress to check it
> >> myself... :)
> >>
> >> Evgeny.
> >>
> >
> > Hi Evgeny,
> >
> > looking at most test failures in Olga's tests, I see that most failures
> are
> > caused by various DB incompatibilities, and have nothing to do with the
> > change itself, but rather with the unit tests themselves not being
> > compatible with a given DB. Olga just logged one issue (CAY-1363) that is
> > actually a bug in Cayenne. Others are similar, such as:
> >
> > * MySQL truncating milliseconds (so the test has to be written to compare
> > with precision up to the nearest second)
> > * Precision and scale not declared for decimal values, causing loss of
> > precision in some DB's
> > * Max length for VARCHAR being 255 on some DBs
> >
> > Those fairly benign issues would cause massive test failures, and
> > potentially hide the real issues. And those affect not only the current
> > patch, but also your earlier commit per
> > http://svn.apache.org/viewvc?view=revision&revision=889168
> >
> > We may need your help to make your tests compatible with other DB's. Olga
> > is about to send a patch on top of your patch fixing some of the above
> > things (and also fix CAY-1363). Can you take it from there and install at
> > least PostgreSQL and MySQL and try to make your tests run on those (in
> > addition to Oracle, HSQLDB, and anything else you might be testing
> against)?
> >
> > This would be of tremendous help to us, as your changes touch on JDBC
> > internals that are very sensitive to DB and driver type and version.
> >
> > Andrus
> >
> >
> >
> >
>
>
> --
> Olga Tkacheva
>



-- 
Olga Tkacheva

RE: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Рябицкий Евгений <er...@diasoft.ru>.
I run tests without my patch over hsqldb, mssql + jtds, posgres
 
Postgres don't like me.... :/


NO PATCH (ONLY TEST)
 
* hsqldb *
 
 Failed tests: 
  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2031, Failures: 7, Errors: 4, Skipped: 0


* SQL Server + JTDS *

Failed tests: 
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2031, Failures: 17, Errors: 5, Skipped: 0


* postgres *

Failed tests: 
  warning(junit.framework.TestSuite$1)
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
  testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testMultiDBUpdate(org.apache.cayenne.access.DataContextCrossDBTest)
  testQualifyOnToMany(org.apache.cayenne.unit.jira.CAY_194Test)
  testQualifyOnToOne(org.apache.cayenne.unit.jira.CAY_194Test)
  testUnregisterThenRegister(org.apache.cayenne.access.ObjectStoreTest)
  testNullifyToOne(org.apache.cayenne.NestedCayenneContextTest)
  testSelect(org.apache.cayenne.NestedCayenneContextTest)
  testDeleteNew(org.apache.cayenne.NestedCayenneContextTest)
  testLocalObjectSynchronize(org.apache.cayenne.NestedCayenneContextTest)
  testLocalObjectsNoOverride(org.apache.cayenne.NestedCayenneContextTest)
  testPrefetchingToOne(org.apache.cayenne.NestedCayenneContextTest)
  testPrefetchingToMany(org.apache.cayenne.NestedCayenneContextTest)
  testCommitChangesToParent(org.apache.cayenne.NestedCayenneContextTest)
  testCommitChangesToParentDeleted(org.apache.cayenne.NestedCayenneContextTest)
  testCommitChanges(org.apache.cayenne.NestedCayenneContextTest)
  testAddRemove(org.apache.cayenne.NestedCayenneContextTest)
  testChangeRel(org.apache.cayenne.NestedCayenneContextTest)
  testCAY1183(org.apache.cayenne.NestedCayenneContextTest)
  testRollbackRelationshipModification(org.apache.cayenne.remote.RemoteRollbackTest)
  testRollbackDeletedObject(org.apache.cayenne.remote.RemoteRollbackTest)
  testRollbackModifiedObject(org.apache.cayenne.remote.RemoteRollbackTest)
  testInsertSubclass(org.apache.cayenne.CayenneContextInheritanceTest)
  testDeepMergeExistingSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
  testDeepMergeNonExistentSubclass(org.apache.cayenne.util.DeepMergeOperationInheritanceTest)
  testPrefetchQuote(org.apache.cayenne.access.DataContexQuoteTest)
  testParentUpdatedId(org.apache.cayenne.remote.NestedObjectContextParentEventsTest)
  testSave(org.apache.cayenne.access.InheritanceTest)
  testInsertSingle(org.apache.cayenne.GenericMappingTest)
  testInsertRelated(org.apache.cayenne.GenericMappingTest)
  testUpdateRelated(org.apache.cayenne.GenericMappingTest)
  testReturnDiffInPrePersist(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
  testReturnDiffClientArcChanges(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
  testReturnIdDiff(org.apache.cayenne.remote.ClientChannelServerDiffsTest)
  testNullify(org.apache.cayenne.remote.RelationshipChangeTest)
  testChange(org.apache.cayenne.remote.RelationshipChangeTest)
  testFailLockingOnToOne(org.apache.cayenne.access.OptimisticLockingTest)
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
  testAddToMany(org.apache.cayenne.CDOMapRelationshipTest)
  testAddToManyViaReverse(org.apache.cayenne.CDOMapRelationshipTest)
  testInsert(org.apache.cayenne.access.EmbeddingTest)
  testAddToMany(org.apache.cayenne.CayenneContextMapRelationshipTest)
  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)
  testNullifyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
  testCascadeToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
  testDenyToOne(org.apache.cayenne.CayenneContextDeleteRulesTest)
  testCascadeToOneNewObject(org.apache.cayenne.CayenneContextDeleteRulesTest)
  testDenyToOne(org.apache.cayenne.access.DeleteRulesTest)
  testNoActionToOne(org.apache.cayenne.access.DeleteRulesTest)
  testNoActionToMany(org.apache.cayenne.access.DeleteRulesTest)
  testNoActionFlattened(org.apache.cayenne.access.DeleteRulesTest)
  testNoActionFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
  testCascadeFlattened(org.apache.cayenne.access.DeleteRulesTest)
  testCascadeFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
  testNullifyFlattened(org.apache.cayenne.access.DeleteRulesTest)
  testNullifyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
  testDenyFlattened(org.apache.cayenne.access.DeleteRulesTest)
  testDenyFlattenedNoReverse(org.apache.cayenne.access.DeleteRulesTest)
  testUpdate(org.apache.cayenne.access.jdbc.SoftDeleteBatchQueryBuilderTest)
  testPeerObjectUpdatedSimpleProperty(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
  testPeerObjectUpdatedToOneRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
  testPeerObjectUpdatedToManyRelationship(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
  testPeerObjectUpdatedTempOID(org.apache.cayenne.remote.NestedObjectContextPeerEventsTest)
  testMultipleSimpleProperties(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
  testComplimentaryArcs(org.apache.cayenne.CayenneContextGraphDiffCompressorTest)
  testDeletion(org.apache.cayenne.remote.CayenneContextDeletionTest)
  testOutParams(org.apache.cayenne.access.DataContextProcedureQueryTest)
  testValidate(org.apache.cayenne.CayenneContextValidationTest)
  testReturnDiffInPrePersist(org.apache.cayenne.CayenneContextServerDiffsTest)
  testReturnDiffInPreUpdate(org.apache.cayenne.CayenneContextServerDiffsTest)
  testReturnDiffClientArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
  testReturnDiffServerArcChanges(org.apache.cayenne.CayenneContextServerDiffsTest)
  testReadRelationship(org.apache.cayenne.CDOOneToManyFKTest)
  testAddToMany(org.apache.cayenne.CDOSetRelationshipTest)
  testAddToManyViaReverse(org.apache.cayenne.CDOSetRelationshipTest)
  testDefault(org.apache.cayenne.remote.RemoteCallbacksTest)
  testServer(org.apache.cayenne.remote.LightSuperClassTest)
  testCollectionMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
  testCollectionNotMemberOfId(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
  testCollectionNotMemberOfToOne(org.apache.cayenne.access.DataContextEJBQLConditionsPeopleTest)
  testInsertJoinWithPK(org.apache.cayenne.FlattenedRelationshipsTest)
  testQualifyOnToManyFlattened(org.apache.cayenne.FlattenedRelationshipsTest)
  testToOneSeriesFlattenedRel(org.apache.cayenne.FlattenedRelationshipsTest)
  testSynchronizeCommit(org.apache.cayenne.access.ClientServerChannelTest)
  testRollbackChanges(org.apache.cayenne.CayenneContextWithDataContextTest)
  testSelectPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
  testCommitChangesPrimitives(org.apache.cayenne.CayenneContextWithDataContextTest)
  testPostAddCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
  testPostAddOnObjectCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
  testPreRemoveCallback(org.apache.cayenne.CayenneContextWithDataContextTest)
  testCAY830(org.apache.cayenne.CayenneContextWithDataContextTest)
  testOIDQueryInterception(org.apache.cayenne.CayenneContextWithDataContextTest)
  testAddToMany(org.apache.cayenne.CDOCollectionRelationshipTest)
  testAddToManyViaReverse(org.apache.cayenne.CDOCollectionRelationshipTest)
  testDelete(org.apache.cayenne.CDOOneToOneFKTest)
  testReadRelationship(org.apache.cayenne.CDOOneToOneFKTest)
  testNewAdd(org.apache.cayenne.CDOOneToOneFKTest)
  test2Null(org.apache.cayenne.CDOOneToOneFKTest)
  testTakeObjectSnapshotDependentFault(org.apache.cayenne.CDOOneToOneFKTest)
  testReplaceNull1(org.apache.cayenne.CDOOneToOneFKTest)
  testReplaceNull2(org.apache.cayenne.CDOOneToOneFKTest)
  testSyncNewObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
  testSyncNewDeletedObject(org.apache.cayenne.CayenneContextClientChannelEventsTest)
  testSyncNewObjectIntoDirtyContext(org.apache.cayenne.CayenneContextClientChannelEventsTest)
  testSyncToManyRelationship(org.apache.cayenne.CayenneContextClientChannelEventsTest)
  testSyncToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
  testSyncManyToManyRelationship1(org.apache.cayenne.CayenneContextClientChannelEventsTest)
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2031, Failures: 23, Errors: 108, Skipped: 0


Evgeny.


-----Original Message-----
From: Ольга Ткачева [mailto:tkachovaolga@gmail.com] 
Sent: Tuesday, January 12, 2010 4:43 PM
To: dev@cayenne.apache.org
Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

in oracle ReturnTypesMappingTest has error generating schema

SEVERE: Error generating schema...
java.sql.SQLException: ORA-01754: a table may contain only one column of
type LONG

    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
    at
oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)

in test generate 2 long column: LONGVARBINARY_COLUMN LONG RAW NULL,
LONGVARCHAR_COLUMN LONG VARCHAR NULL


12 января 2010 г. 11:48 пользователь Andrus Adamchik <andrus@objectstyle.org
> написал:

>
> On Jan 11, 2010, at 1:45 PM, Рябицкий Евгений wrote:
>
>  Strange result... looks like I have to install Postgress to check it
>> myself... :)
>>
>> Evgeny.
>>
>
> Hi Evgeny,
>
> looking at most test failures in Olga's tests, I see that most failures are
> caused by various DB incompatibilities, and have nothing to do with the
> change itself, but rather with the unit tests themselves not being
> compatible with a given DB. Olga just logged one issue (CAY-1363) that is
> actually a bug in Cayenne. Others are similar, such as:
>
> * MySQL truncating milliseconds (so the test has to be written to compare
> with precision up to the nearest second)
> * Precision and scale not declared for decimal values, causing loss of
> precision in some DB's
> * Max length for VARCHAR being 255 on some DBs
>
> Those fairly benign issues would cause massive test failures, and
> potentially hide the real issues. And those affect not only the current
> patch, but also your earlier commit per
> http://svn.apache.org/viewvc?view=revision&revision=889168
>
> We may need your help to make your tests compatible with other DB's. Olga
> is about to send a patch on top of your patch fixing some of the above
> things (and also fix CAY-1363). Can you take it from there and install at
> least PostgreSQL and MySQL and try to make your tests run on those (in
> addition to Oracle, HSQLDB, and anything else you might be testing against)?
>
> This would be of tremendous help to us, as your changes touch on JDBC
> internals that are very sensitive to DB and driver type and version.
>
> Andrus
>
>
>
>


-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Ольга Ткачева <tk...@gmail.com>.
in oracle ReturnTypesMappingTest has error generating schema

SEVERE: Error generating schema...
java.sql.SQLException: ORA-01754: a table may contain only one column of
type LONG

    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:573)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1891)
    at
oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1093)

in test generate 2 long column: LONGVARBINARY_COLUMN LONG RAW NULL,
LONGVARCHAR_COLUMN LONG VARCHAR NULL


12 января 2010 г. 11:48 пользователь Andrus Adamchik <andrus@objectstyle.org
> написал:

>
> On Jan 11, 2010, at 1:45 PM, Рябицкий Евгений wrote:
>
>  Strange result... looks like I have to install Postgress to check it
>> myself... :)
>>
>> Evgeny.
>>
>
> Hi Evgeny,
>
> looking at most test failures in Olga's tests, I see that most failures are
> caused by various DB incompatibilities, and have nothing to do with the
> change itself, but rather with the unit tests themselves not being
> compatible with a given DB. Olga just logged one issue (CAY-1363) that is
> actually a bug in Cayenne. Others are similar, such as:
>
> * MySQL truncating milliseconds (so the test has to be written to compare
> with precision up to the nearest second)
> * Precision and scale not declared for decimal values, causing loss of
> precision in some DB's
> * Max length for VARCHAR being 255 on some DBs
>
> Those fairly benign issues would cause massive test failures, and
> potentially hide the real issues. And those affect not only the current
> patch, but also your earlier commit per
> http://svn.apache.org/viewvc?view=revision&revision=889168
>
> We may need your help to make your tests compatible with other DB's. Olga
> is about to send a patch on top of your patch fixing some of the above
> things (and also fix CAY-1363). Can you take it from there and install at
> least PostgreSQL and MySQL and try to make your tests run on those (in
> addition to Oracle, HSQLDB, and anything else you might be testing against)?
>
> This would be of tremendous help to us, as your changes touch on JDBC
> internals that are very sensitive to DB and driver type and version.
>
> Andrus
>
>
>
>


-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Andrus Adamchik <an...@objectstyle.org>.
On Jan 11, 2010, at 1:45 PM, Рябицкий Евгений wrote:

> Strange result... looks like I have to install Postgress to check it  
> myself... :)
>
> Evgeny.

Hi Evgeny,

looking at most test failures in Olga's tests, I see that most  
failures are caused by various DB incompatibilities, and have nothing  
to do with the change itself, but rather with the unit tests  
themselves not being compatible with a given DB. Olga just logged one  
issue (CAY-1363) that is actually a bug in Cayenne. Others are  
similar, such as:

* MySQL truncating milliseconds (so the test has to be written to  
compare with precision up to the nearest second)
* Precision and scale not declared for decimal values, causing loss of  
precision in some DB's
* Max length for VARCHAR being 255 on some DBs

Those fairly benign issues would cause massive test failures, and  
potentially hide the real issues. And those affect not only the  
current patch, but also your earlier commit per http://svn.apache.org/viewvc?view=revision&revision=889168

We may need your help to make your tests compatible with other DB's.  
Olga is about to send a patch on top of your patch fixing some of the  
above things (and also fix CAY-1363). Can you take it from there and  
install at least PostgreSQL and MySQL and try to make your tests run  
on those (in addition to Oracle, HSQLDB, and anything else you might  
be testing against)?

This would be of tremendous help to us, as your changes touch on JDBC  
internals that are very sensitive to DB and driver type and version.

Andrus




Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Ольга Ткачева <tk...@gmail.com>.
I have run tests on 3.0. results:

*postgres
*
Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 2083, Failures: 0, Errors: 1, Skipped: 0

*mysql*

Tests in error:
  test1MBClob(org.apache.cayenne.access.DataContextClobTest)
  test1MBBlob(org.apache.cayenne.access.DataContextBlobTest)

Tests run: 2083, Failures: 0, Errors: 2, Skipped: 0


*sqlserver*

Failed tests:
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)

Tests run: 2083, Failures: 1, Errors: 0, Skipped: 0


11 января 2010 г. 13:45 пользователь Рябицкий Евгений <
eryabitskiy@diasoft.ru> написал:

> Strange result... looks like I have to install Postgress to check it
> myself... :)
>
> Evgeny.
>
>
>
> -----Original Message-----
> From: Ольга Ткачева [mailto:tkachovaolga@gmail.com]
> Sent: Monday, January 11, 2010 2:06 PM
> To: dev@cayenne.apache.org
> Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected
> values in Row Queries
>
> I apply the latest patch from this Jira locally and run a test.
>
> *Result without the patch*
>
> *mysql* - all ok
>
> *sqlserver*
>
> Failed tests:
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
>
> Tests run: 1986, Failures: 3, Errors: 0, Skipped: 0
>
> *postgres*
>
> Failed tests:
>  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>
> Tests in error:
>  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
>  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)
>
> Tests run: 1986, Failures: 3, Errors: 2, Skipped: 0
>
>
>
> *Result with the patch*
>
> *mysql*
>
> Failed tests:
>  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>
> Tests run: 2030, Failures: 3, Errors: 0, Skipped: 0
>
>
> *sqlserver*
>
> Failed tests:
>  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>
>
> testSelectWithRowDescriptor(org.apache.cayenne.access.DataContextProcedureQueryTest)
>  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests run: 2030, Failures: 11, Errors: 4, Skipped: 0
>
>
> *postgres*
>
> Failed tests:
>  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>
>
> testSelectWithRowDescriptor(org.apache.cayenne.access.DataContextProcedureQueryTest)
>  testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
>  testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
>
> Tests in error:
>  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
>  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)
>
> Tests run: 2030, Failures: 26, Errors: 2, Skipped: 0
>
>
>
>
> 2010/1/10 Andrus Adamchik (JIRA) <ji...@apache.org>
>
> >
> >    [
> >
> https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798458#action_12798458
> ]
> >
> > Andrus Adamchik commented on CAY-1354:
> > --------------------------------------
> >
> > Next week myself or Olga may try to test this patch in our environment
> that
> > includes PostgreSQL and SQLServer (I think the later was causing
> trouble)...
> >
> > > Wrong Types mapping for selected values in Row Queries
> > > ------------------------------------------------------
> > >
> > >                 Key: CAY-1354
> > >                 URL: https://issues.apache.org/jira/browse/CAY-1354
> > >             Project: Cayenne
> > >          Issue Type: Bug
> > >          Components: Core Library
> > >    Affects Versions: 3.1M1
> > >            Reporter: Evgeny Ryabitskiy
> > >            Assignee: Evgeny Ryabitskiy
> > >            Priority: Critical
> > >             Fix For: 3.1M1
> > >
> > >         Attachments: CAY-1354.patch, CAY-1354_TEST.patch,
> > ReturnTypesMappingTest.java
> > >
> > >
> > >  By default every SQL type is mapped to some Java type by modeler.
> > > I am expecting same behavior in common DataRow queries (without ORM).
> > > But in fact half of types are not mapped correctly....
> > > Attached JUnit test can to explain problem with more details...
> >
> > --
> > This message is automatically generated by JIRA.
> > -
> > You can reply to this email to add a comment to the issue online.
> >
> >
>
>
> --
> Olga Tkacheva
>



-- 
Olga Tkacheva

RE: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Рябицкий Евгений <er...@diasoft.ru>.
Strange result... looks like I have to install Postgress to check it myself... :)

Evgeny.



-----Original Message-----
From: Ольга Ткачева [mailto:tkachovaolga@gmail.com] 
Sent: Monday, January 11, 2010 2:06 PM
To: dev@cayenne.apache.org
Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

I apply the latest patch from this Jira locally and run a test.

*Result without the patch*

*mysql* - all ok

*sqlserver*

Failed tests:
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)

Tests run: 1986, Failures: 3, Errors: 0, Skipped: 0

*postgres*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)

Tests run: 1986, Failures: 3, Errors: 2, Skipped: 0



*Result with the patch*

*mysql*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests run: 2030, Failures: 3, Errors: 0, Skipped: 0


*sqlserver*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

testSelectWithRowDescriptor(org.apache.cayenne.access.DataContextProcedureQueryTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error:
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2030, Failures: 11, Errors: 4, Skipped: 0


*postgres*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

testSelectWithRowDescriptor(org.apache.cayenne.access.DataContextProcedureQueryTest)
  testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)

Tests run: 2030, Failures: 26, Errors: 2, Skipped: 0




2010/1/10 Andrus Adamchik (JIRA) <ji...@apache.org>

>
>    [
> https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798458#action_12798458]
>
> Andrus Adamchik commented on CAY-1354:
> --------------------------------------
>
> Next week myself or Olga may try to test this patch in our environment that
> includes PostgreSQL and SQLServer (I think the later was causing trouble)...
>
> > Wrong Types mapping for selected values in Row Queries
> > ------------------------------------------------------
> >
> >                 Key: CAY-1354
> >                 URL: https://issues.apache.org/jira/browse/CAY-1354
> >             Project: Cayenne
> >          Issue Type: Bug
> >          Components: Core Library
> >    Affects Versions: 3.1M1
> >            Reporter: Evgeny Ryabitskiy
> >            Assignee: Evgeny Ryabitskiy
> >            Priority: Critical
> >             Fix For: 3.1M1
> >
> >         Attachments: CAY-1354.patch, CAY-1354_TEST.patch,
> ReturnTypesMappingTest.java
> >
> >
> >  By default every SQL type is mapped to some Java type by modeler.
> > I am expecting same behavior in common DataRow queries (without ORM).
> > But in fact half of types are not mapped correctly....
> > Attached JUnit test can to explain problem with more details...
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>


-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Andrey Razumovsky <ra...@gmail.com>.
11 января 2010 г. 17:03 пользователь Рябицкий Евгений <
eryabitskiy@diasoft.ru> написал:

> Can't imagine how EJBQLQueryTest is related to my changes. Should see some
> logs...
>

As I already wrote, EJBQLQueryTest fails to my changes:
http://cayenne.markmail.org/search/#query:+page:2+mid:nmtd4haq53lvqoay+state:results

RE: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Рябицкий Евгений <er...@diasoft.ru>.
Still little bit confusing...


>I apply the latest patch from this Jira locally and run a test.
>>
>> *Result without the patch*
>>
>> *mysql* - all ok
>>

>it hsqldb - ok


So you applied patch or only add tests?
Tests shouldn't work on hsqldb without patch. At least I check everything on hsqldb and get everything working there before publishing patch.


I guess... sections for *Result without the patch* and *Result with the patch* should be switched? :) or it looks like my patch broke everything?

Also this tests assertation should be fixed (I will publish newer patch including that fixes)
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)


So there still:

*postgres*

Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)

Second one is mine and quite new. It can be not well written.
Can't imagine how EJBQLQueryTest is related to my changes. Should see some logs...

*sqlserver*

Failed tests:
testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)

Also strange fail. Can be related to some strange type assert.


Evgeny.



-----Original Message-----
From: Ольга Ткачева [mailto:tkachovaolga@gmail.com] 
Sent: Monday, January 11, 2010 4:47 PM
To: dev@cayenne.apache.org
Subject: Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

sorry, i have confused results mysql and hsqldb


I apply the latest patch from this Jira locally and run a test.
>
> *Result without the patch*
>
> *mysql* - all ok
>

it hsqldb - ok

mysql have old errors

Tests in error:
  test1MBClob(org.apache.cayenne.access.DataContextClobTest)
  test1MBBlob(org.apache.cayenne.access.DataContextBlobTest)

Tests run: 2083, Failures: 0, Errors: 2, Skipped: 0


>
> *Result with the patch*
>
> *mysql*
>
> Failed tests:
>   testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>   testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>   testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>
> Tests run: 2030, Failures: 3, Errors: 0, Skipped: 0
>
>

it hsqldb have this errors





>
>
>
>
> 2010/1/10 Andrus Adamchik (JIRA) <ji...@apache.org>
>
>
>>    [
>> https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798458#action_12798458]
>>
>> Andrus Adamchik commented on CAY-1354:
>> --------------------------------------
>>
>> Next week myself or Olga may try to test this patch in our environment
>> that includes PostgreSQL and SQLServer (I think the later was causing
>> trouble)...
>>
>> > Wrong Types mapping for selected values in Row Queries
>> > ------------------------------------------------------
>> >
>> >                 Key: CAY-1354
>> >                 URL: https://issues.apache.org/jira/browse/CAY-1354
>> >             Project: Cayenne
>> >          Issue Type: Bug
>> >          Components: Core Library
>> >    Affects Versions: 3.1M1
>> >            Reporter: Evgeny Ryabitskiy
>> >            Assignee: Evgeny Ryabitskiy
>> >            Priority: Critical
>> >             Fix For: 3.1M1
>> >
>> >         Attachments: CAY-1354.patch, CAY-1354_TEST.patch,
>> ReturnTypesMappingTest.java
>> >
>> >
>> >  By default every SQL type is mapped to some Java type by modeler.
>> > I am expecting same behavior in common DataRow queries (without ORM).
>> > But in fact half of types are not mapped correctly....
>> > Attached JUnit test can to explain problem with more details...
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> You can reply to this email to add a comment to the issue online.
>>
>>
>
>
> --
> Olga Tkacheva
>



-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Ольга Ткачева <tk...@gmail.com>.
sorry, i have confused results mysql and hsqldb


I apply the latest patch from this Jira locally and run a test.
>
> *Result without the patch*
>
> *mysql* - all ok
>

it hsqldb - ok

mysql have old errors

Tests in error:
  test1MBClob(org.apache.cayenne.access.DataContextClobTest)
  test1MBBlob(org.apache.cayenne.access.DataContextBlobTest)

Tests run: 2083, Failures: 0, Errors: 2, Skipped: 0


>
> *Result with the patch*
>
> *mysql*
>
> Failed tests:
>   testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
>   testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
>   testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
>
> Tests run: 2030, Failures: 3, Errors: 0, Skipped: 0
>
>

it hsqldb have this errors





>
>
>
>
> 2010/1/10 Andrus Adamchik (JIRA) <ji...@apache.org>
>
>
>>    [
>> https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798458#action_12798458]
>>
>> Andrus Adamchik commented on CAY-1354:
>> --------------------------------------
>>
>> Next week myself or Olga may try to test this patch in our environment
>> that includes PostgreSQL and SQLServer (I think the later was causing
>> trouble)...
>>
>> > Wrong Types mapping for selected values in Row Queries
>> > ------------------------------------------------------
>> >
>> >                 Key: CAY-1354
>> >                 URL: https://issues.apache.org/jira/browse/CAY-1354
>> >             Project: Cayenne
>> >          Issue Type: Bug
>> >          Components: Core Library
>> >    Affects Versions: 3.1M1
>> >            Reporter: Evgeny Ryabitskiy
>> >            Assignee: Evgeny Ryabitskiy
>> >            Priority: Critical
>> >             Fix For: 3.1M1
>> >
>> >         Attachments: CAY-1354.patch, CAY-1354_TEST.patch,
>> ReturnTypesMappingTest.java
>> >
>> >
>> >  By default every SQL type is mapped to some Java type by modeler.
>> > I am expecting same behavior in common DataRow queries (without ORM).
>> > But in fact half of types are not mapped correctly....
>> > Attached JUnit test can to explain problem with more details...
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> You can reply to this email to add a comment to the issue online.
>>
>>
>
>
> --
> Olga Tkacheva
>



-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Ольга Ткачева <tk...@gmail.com>.
I apply the latest patch from this Jira locally and run a test.

*Result without the patch*

*mysql* - all ok

*sqlserver*

Failed tests:
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)

Tests run: 1986, Failures: 3, Errors: 0, Skipped: 0

*postgres*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)

Tests run: 1986, Failures: 3, Errors: 2, Skipped: 0



*Result with the patch*

*mysql*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests run: 2030, Failures: 3, Errors: 0, Skipped: 0


*sqlserver*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

testSelectWithRowDescriptor(org.apache.cayenne.access.DataContextProcedureQueryTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error:
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2030, Failures: 11, Errors: 4, Skipped: 0


*postgres*

Failed tests:
  testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
  testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

testSelectWithRowDescriptor(org.apache.cayenne.access.DataContextProcedureQueryTest)
  testBIGINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBIT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBOOLEAN(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testCLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDOUBLE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testINTEGER(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARCHAR(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)
  testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)

Tests run: 2030, Failures: 26, Errors: 2, Skipped: 0




2010/1/10 Andrus Adamchik (JIRA) <ji...@apache.org>

>
>    [
> https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798458#action_12798458]
>
> Andrus Adamchik commented on CAY-1354:
> --------------------------------------
>
> Next week myself or Olga may try to test this patch in our environment that
> includes PostgreSQL and SQLServer (I think the later was causing trouble)...
>
> > Wrong Types mapping for selected values in Row Queries
> > ------------------------------------------------------
> >
> >                 Key: CAY-1354
> >                 URL: https://issues.apache.org/jira/browse/CAY-1354
> >             Project: Cayenne
> >          Issue Type: Bug
> >          Components: Core Library
> >    Affects Versions: 3.1M1
> >            Reporter: Evgeny Ryabitskiy
> >            Assignee: Evgeny Ryabitskiy
> >            Priority: Critical
> >             Fix For: 3.1M1
> >
> >         Attachments: CAY-1354.patch, CAY-1354_TEST.patch,
> ReturnTypesMappingTest.java
> >
> >
> >  By default every SQL type is mapped to some Java type by modeler.
> > I am expecting same behavior in common DataRow queries (without ORM).
> > But in fact half of types are not mapped correctly....
> > Attached JUnit test can to explain problem with more details...
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>


-- 
Olga Tkacheva

Re: [jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by Evgeny Ryabitskiy <ev...@gmail.com>.
I merged my new patch with Olga's changes.

Almost everything is working!!!

SQL Server + JTDS

Failed tests:
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error:
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)

Tests run: 2032, Failures: 3, Errors: 1, Skipped: 0

first 2 was before.

2 last are related to JTDS Driver specific....
testFLOAT: http://jtds.sourceforge.net/typemap.html
testLongIn - JTDS limit for parameters is 2000 (test is using 2006)

Posgres

Failed tests:
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error:
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 2032, Failures: 3, Errors: 1, Skipped: 0

testNullParameter was before.


So If no body mind I will commit this stuff? :)


Evgeny.



2010/1/13 Evgeny Ryabitskiy (JIRA) <ji...@apache.org>:
>
>    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799737#action_12799737 ]
>
> Evgeny Ryabitskiy commented on CAY-1354:
> ----------------------------------------
>
> So you can see that my changes didn't break anything.
> I suggest to commit changes and successful tests and think what to do with what left.
>
>> Wrong Types mapping for selected values in Row Queries
>> ------------------------------------------------------
>>
>>                 Key: CAY-1354
>>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>>             Project: Cayenne
>>          Issue Type: Bug
>>          Components: Core Library
>>    Affects Versions: 3.1M1
>>            Reporter: Evgeny Ryabitskiy
>>            Assignee: Evgeny Ryabitskiy
>>            Priority: Critical
>>             Fix For: 3.1M1
>>
>>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>>
>>
>>  By default every SQL type is mapped to some Java type by modeler.
>> I am expecting same behavior in common DataRow queries (without ORM).
>> But in fact half of types are not mapped correctly....
>> Attached JUnit test can to explain problem with more details...
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>

[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: 0002-CAY-1354.patch

Merge my changes with solution for java.sql.SQLException: ORA-01754: a table may contain only one column of type LONG 


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798458#action_12798458 ] 

Andrus Adamchik commented on CAY-1354:
--------------------------------------

Next week myself or Olga may try to test this patch in our environment that includes PostgreSQL and SQLServer (I think the later was causing trouble)...

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: 0003-CAY-1354.patch

Changes equals assertion to compare strings for Date, Time and Timestamp.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12797100#action_12797100 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

Yeah.. so I think that 2 issues was fixed in CAY-1259 by me. And now it is working.

Actually I wasn't first who pointed on wrong lines here CAY-1052 but solution wasn't best I think...

Also all tests are passed. My patch didn't broke anything... or we have not so good coverage and tests didn't catch regression....


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12795558#action_12795558 ] 

Andrus Adamchik commented on CAY-1354:
--------------------------------------

There are a few cases involved here:

1. A DataRow clearly belongs to a certain ObjEntity. Then we have the explicit Java type for each DB type and should return it in a DataRow. As in:

  SelectQuery q = new SelectQuery(Artist.class);
  q.setFetchingDataRows(true);

2. A DataRow can not be easily attributed to a single DbEntity. Then the result should correspond to a default JDBC to Java mapping. This mught be the case with SQLTemplate.

In your test you emulate case #2, so I don't think it is possible to match it back to the original type if such type is not a JDBC default mapping. (in addition there's a difference between the drivers in how they interpret the mapping, so it can get hairy real quick) So can you tell us which tests are failing? 

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: CAY-1354.patch

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>             Fix For: 2.0.5, 3.0.1, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrus Adamchik updated CAY-1354:
---------------------------------

    Fix Version/s: 2.0.5

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 2.0.5, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: 0004-CAY-1354.patch

Returned not used methods. but marked as depricated.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12795252#action_12795252 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

For me It is critical issue because we are using RowQueries in most cases (for optimization).

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Priority: Critical
>         Attachments: ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: CAY-1354.patch

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy reassigned CAY-1354:
--------------------------------------

    Assignee: Evgeny Ryabitskiy

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>         Attachments: ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799734#action_12799734 ] 

Evgeny Ryabitskiy edited comment on CAY-1354 at 1/14/10 9:36 AM:
-----------------------------------------------------------------

Merged with last commit.
fuf....!

Final result:

* SQL Server + JTDS *

 WITHOUT PATCH

Failed tests: 
  testShouldMergeChanges(org.apache.cayenne.access.DataContextDelegateSharedCacheTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)

Tests run: 1987, Failures: 3, Errors: 1, Skipped: 0

 WITH PATCH

Failed tests: 
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)

Tests run: 2032, Failures: 3, Errors: 1, Skipped: 0


* postgres *

 WITHOUT PATCH

Tests in error: 
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 1987, Failures: 0, Errors: 1, Skipped: 0

 WITH PATCH

Failed tests: 
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 2031, Failures: 3, Errors: 1, Skipped: 0

      was (Author: apparition):
    Merged with last commit.
fuf....!

Final result:

* SQL Server + JTDS *

 WITHOUT PATCH

Failed tests: 
  testShouldMergeChanges(org.apache.cayenne.access.DataContextDelegateSharedCacheTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)

Tests run: 1987, Failures: 3, Errors: 1, Skipped: 0

 WITH PATCH

Failed tests: 
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2031, Failures: 8, Errors: 5, Skipped: 0


* postgres *

 WITHOUT PATCH

Tests in error: 
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 1987, Failures: 0, Errors: 1, Skipped: 0

 WITH PATCH

Failed tests: 
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 2031, Failures: 3, Errors: 1, Skipped: 0
  
> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799028#action_12799028 ] 

Evgeny Ryabitskiy edited comment on CAY-1354 at 1/12/10 2:31 AM:
-----------------------------------------------------------------

for conclusion, Olga's test shown next JUnits fail related to my changes:


*sqlserver*

Failed tests:
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)


*postgres*

Failed tests:
 testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests in error:
 testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)


      was (Author: apparition):
    for conclusion, Olga's test shown next tests fail related to my changes:


*sqlserver*

Failed tests:
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)


*postgres*

Failed tests:
 testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests in error:
 testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)

  
> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12795580#action_12795580 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

So my idea is that default mapping in case #2 should be same as default mapping in modeler and should be same for all drivers and DBs.

It should be documented once and supported  for all versions. It will allow to do cross-DB applications and increase there stability.

Failed tests: 
  testDATE(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testREAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testSMALLINT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIMESTAMP(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testLONGVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Olga Tkacheva (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Olga Tkacheva updated CAY-1354:
-------------------------------

    Attachment: 0001-CAY-1354.patch

I added some change to Evgeny's patch (Date of patch: 2010-01-12 02:22 AM) I changed only the testmap.map.xml.
If you will run tests on oracle: you will have this error

SEVERE: Error generating schema...
java.sql.SQLException: ORA-01754: a table may contain only one column of type LONG
 
I wrote about it in letter to dev-list.


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: CAY-1354_TEST.patch

Publishing a patch because test requires DomainMap changes.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12797026#action_12797026 ] 

Andrus Adamchik commented on CAY-1354:
--------------------------------------

Here is the commit that introduced this code. It was a response to a user issue (also with SQLTemplate), so looks like this thing varies by driver and reverting current policy may result in problems elsewere. So I suggest that we don't apply January 6 patch unless we can confirm that the old issue does not reemerge.


commit ffff9cdaa8d407d31b3c4e289e228a3e33816c24
Author: Andrus Adamchik <aa...@apache.org>
Date:   Fri May 9 08:25:56 2008 +0000

    CAY-672 Change the logic to get the Java class from ResultSetMetadata
    CAY-1052  Invalid cast on NUMERICs with scale of 0 using Postgres JDBC 8.2+
    
    git-svn-id: https://svn.apache.org/repos/asf/cayenne/main/branches/STABLE-1.2@654717 13f79535-47bb-0310-9956-ffa450edef68

diff --git a/cayenne/cayenne-java/src/cayenne/java/org/objectstyle/cayenne/access/jdbc/ColumnDescriptor.java b/cayenne/cayenne-java/src
index c8a7c54..b5feca4 100644
--- a/cayenne/cayenne-java/src/cayenne/java/org/objectstyle/cayenne/access/jdbc/ColumnDescriptor.java
+++ b/cayenne/cayenne-java/src/cayenne/java/org/objectstyle/cayenne/access/jdbc/ColumnDescriptor.java
@@ -189,8 +189,7 @@ public class ColumnDescriptor implements Serializable {
         this.qualifiedColumnName = name;
         this.label = name;
         this.jdbcType = metaData.getColumnType(position);
-        this.javaClass = getDefaultJavaClass(metaData.getColumnDisplaySize(position),
-                metaData.getScale(position));
+        this.javaClass = metaData.getColumnClassName(position);
     }
 
     /**
@@ -355,4 +354,4 @@ public class ColumnDescriptor implements Serializable {
     public void setLabel(String columnName) {
         this.label = columnName;
     }
-}
\ No newline at end of file
+}



> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799028#action_12799028 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

for conclusion, Olga's test shown next tests fail related to my changes:


*sqlserver*

Failed tests:
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)


*postgres*

Failed tests:
 testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest)

Tests in error:
 testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest)


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799688#action_12799688 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

Ok. I will return it. Just removed it in a hurry for a draft version.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy closed CAY-1354.
----------------------------------

    Resolution: Fixed

Fixed to all (2.0, 3/0, 3.1) branches, closing.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 2.0.5, 3.0-final, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Fix Version/s: 3.1M1

Going to fix it in 3.1 release.
Does everyone agree with my right type mapping suggestions?

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment:     (was: CAY-1354.patch)

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>             Fix For: 2.0.5, 3.0.1, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrey Razumovsky (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrey Razumovsky updated CAY-1354:
-----------------------------------

    Priority: Major  (was: Critical)

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>             Fix For: 2.0.5, 3.0.1, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12795558#action_12795558 ] 

Andrus Adamchik edited comment on CAY-1354 at 12/31/09 7:45 AM:
----------------------------------------------------------------

There are a few cases involved here:

1. A DataRow clearly belongs to a certain ObjEntity. Then we have the explicit Java type for each DB type and should return it in a DataRow. As in:

  SelectQuery q = new SelectQuery(Artist.class);
  q.setFetchingDataRows(true);

2. A DataRow can not be easily attributed to a single ObjEntity. Then the result should correspond to a default JDBC to Java mapping. This might be the case with SQLTemplate.

In your test you emulate case #2, so I don't think it is possible to match it back to the original type if such type is not a JDBC default mapping. (in addition there's a difference between the drivers in how they interpret the mapping, so it can get hairy real quick) So can you tell us which tests are failing? 

      was (Author: andrus):
    There are a few cases involved here:

1. A DataRow clearly belongs to a certain ObjEntity. Then we have the explicit Java type for each DB type and should return it in a DataRow. As in:

  SelectQuery q = new SelectQuery(Artist.class);
  q.setFetchingDataRows(true);

2. A DataRow can not be easily attributed to a single ObjEntity. Then the result should correspond to a default JDBC to Java mapping. This mught be the case with SQLTemplate.

In your test you emulate case #2, so I don't think it is possible to match it back to the original type if such type is not a JDBC default mapping. (in addition there's a difference between the drivers in how they interpret the mapping, so it can get hairy real quick) So can you tell us which tests are failing? 
  
> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Fix Version/s: 3.0-final

Finally this fix took place in 3.0 branch.
Now this issue can be closed.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 2.0.5, 3.0-final, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12795253#action_12795253 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

Result on 3.1 trunk:   

4 errors (exception while query) + 7 fails (no type match)  rom 22 DataRow  query tests (half of types are not working)


22/22 ORM query test are successful


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>         Attachments: ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12800157#action_12800157 ] 

Evgeny Ryabitskiy edited comment on CAY-1354 at 1/14/10 10:22 AM:
------------------------------------------------------------------

Committed.

There is same problem with mapping of float for SQLServer and Posgres.
Both drivers maping it to DOUBLE JDBC type.

Thinking about to follow it in our Cayenne mapping.

      was (Author: apparition):
    Committed.

There is same problem with mapping of float for SQLServer and Posgres.
Both drivers maps it to DOUBLE JDBC type.

Thinking about to follow it in our Cayenne mapping.
  
> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12800157#action_12800157 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

Committed.

There is same problem with mapping of float for SQLServer and Posgres.
Both drivers maps it to DOUBLE JDBC type.

Thinking about to follow it in our Cayenne mapping.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrus Adamchik updated CAY-1354:
---------------------------------

    Fix Version/s:     (was: 3.0-final)
                   3.0.1

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 2.0.5, 3.0.1, 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Andrus Adamchik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12795558#action_12795558 ] 

Andrus Adamchik edited comment on CAY-1354 at 12/31/09 7:44 AM:
----------------------------------------------------------------

There are a few cases involved here:

1. A DataRow clearly belongs to a certain ObjEntity. Then we have the explicit Java type for each DB type and should return it in a DataRow. As in:

  SelectQuery q = new SelectQuery(Artist.class);
  q.setFetchingDataRows(true);

2. A DataRow can not be easily attributed to a single ObjEntity. Then the result should correspond to a default JDBC to Java mapping. This mught be the case with SQLTemplate.

In your test you emulate case #2, so I don't think it is possible to match it back to the original type if such type is not a JDBC default mapping. (in addition there's a difference between the drivers in how they interpret the mapping, so it can get hairy real quick) So can you tell us which tests are failing? 

      was (Author: andrus):
    There are a few cases involved here:

1. A DataRow clearly belongs to a certain ObjEntity. Then we have the explicit Java type for each DB type and should return it in a DataRow. As in:

  SelectQuery q = new SelectQuery(Artist.class);
  q.setFetchingDataRows(true);

2. A DataRow can not be easily attributed to a single DbEntity. Then the result should correspond to a default JDBC to Java mapping. This mught be the case with SQLTemplate.

In your test you emulate case #2, so I don't think it is possible to match it back to the original type if such type is not a JDBC default mapping. (in addition there's a difference between the drivers in how they interpret the mapping, so it can get hairy real quick) So can you tell us which tests are failing? 
  
> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: 0005-CAY-1354.patch

Merged with last commit.
fuf....!

Final result:

* SQL Server + JTDS *

 WITHOUT PATCH

Failed tests: 
  testShouldMergeChanges(org.apache.cayenne.access.DataContextDelegateSharedCacheTest)
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)

Tests run: 1987, Failures: 3, Errors: 1, Skipped: 0

 WITH PATCH

Failed tests: 
  testFetchLimitWithOffset(org.apache.cayenne.query.SelectQueryTest)
  testSelectLikeCaseSensitive(org.apache.cayenne.query.SelectQueryTest)
  testDECIMAL(org.apache.cayenne.access.ReturnTypesMappingTest)
  testDECIMAL2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC(org.apache.cayenne.access.ReturnTypesMappingTest)
  testNUMERIC2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTIME(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testLongIn(org.apache.cayenne.exp.ExpressionFactoryTest)
  testBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY(org.apache.cayenne.access.ReturnTypesMappingTest)
  testVARBINARY2(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests run: 2031, Failures: 8, Errors: 5, Skipped: 0


* postgres *

 WITHOUT PATCH

Tests in error: 
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 1987, Failures: 0, Errors: 1, Skipped: 0

 WITH PATCH

Failed tests: 
  testBLOB(org.apache.cayenne.access.ReturnTypesMappingTest)
  testFLOAT(org.apache.cayenne.access.ReturnTypesMappingTest)
  testTINYINT(org.apache.cayenne.access.ReturnTypesMappingTest)

Tests in error: 
  testNullParameter(org.apache.cayenne.query.EJBQLQueryTest)

Tests run: 2031, Failures: 3, Errors: 1, Skipped: 0

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799737#action_12799737 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

So you can see that my changes didn't break anything.
I suggest to commit changes and successful tests and think what to do with what left.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799031#action_12799031 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

Time/date related JUnits should be fixed in last patch on 2010-01-12

 testSQLTemplateTimestamp(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateDate(org.apache.cayenne.access.DateTimeTypesTest)
 testSQLTemplateTime(org.apache.cayenne.access.DateTimeTypesTest) 

Still should see what is happening in 
 testBindingForCollection(org.apache.cayenne.access.jdbc.BindDirectiveTest) 
on Posgres


> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: ReturnTypesMappingTest.java

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Priority: Critical
>         Attachments: ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: 0006-CAY-1354.patch

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: CAY-1354_2.0.patch

This is patch for 2.0
To move logic of Java type resolving from driver to Cayenne type mapping.
Reason: Drivers can return here different types (even some specific like com.oracle.TIMESTAMP)

3.1 trunk is already fixed.
Why 2.0 should be patched? Because current logic (witch returns driver specific types) is really far from our last release ( 2.0.4 ) which doesn't rely on drivers. 
So I suggest to fix it in all branches (even 3.0 that is going to release soon).

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, 0004-CAY-1354.patch, 0005-CAY-1354.patch, 0006-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_2.0.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: CAY-1354.patch

That is my changes + tests. If no one mind I will commit it in the evening.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12796984#action_12796984 ] 

Evgeny Ryabitskiy commented on CAY-1354:
----------------------------------------

after some code inspection I found out that the problem is in JDBC drivers, we are using metaData.getColumnClassName(position); that can return driver specific JAVA type (how it was with Oracle).

My idea is to use Cayenne TypeMapping for it. So I changed few lines and wow... we can delete all that Oracle stuff from my last commits :)))
It is funny.....

One thing is that we should document (I mean user documentation) this type mapping.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Cayenne Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Evgeny Ryabitskiy updated CAY-1354:
-----------------------------------

    Attachment: CAY-1354.patch

Add last one version of patch

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Ari Maniatis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799664#action_12799664 ] 

Ari Maniatis commented on CAY-1354:
-----------------------------------

Is it possible to deprecate the public functions you removed like  ColumnDescriptor(String, int, String)? Typically the old versions should stay around for a couple of releases, or if that isn't possible, warnings need to be placed in the upgrade guide.

> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: 0001-CAY-1354.patch, 0002-CAY-1354.patch, 0003-CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAY-1354) Wrong Types mapping for selected values in Row Queries

Posted by "Evgeny Ryabitskiy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAY-1354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12797100#action_12797100 ] 

Evgeny Ryabitskiy edited comment on CAY-1354 at 1/6/10 12:45 PM:
-----------------------------------------------------------------

Yeah.. so I think that 2 issues was fixed in CAY-1259 by me. And now it is working.

Actually I wasn't first who pointed on wrong lines here CAY-1052 but solution wasn't best I think...

Also all tests are passed. My patch didn't broke anything... or we have not so good coverage and tests didn't catch regression....


I don't have Postgress so I can't check CAY-1052 but I'm sure for 95% that it is not related to my changes.


      was (Author: apparition):
    Yeah.. so I think that 2 issues was fixed in CAY-1259 by me. And now it is working.

Actually I wasn't first who pointed on wrong lines here CAY-1052 but solution wasn't best I think...

Also all tests are passed. My patch didn't broke anything... or we have not so good coverage and tests didn't catch regression....

  
> Wrong Types mapping for selected values in Row Queries
> ------------------------------------------------------
>
>                 Key: CAY-1354
>                 URL: https://issues.apache.org/jira/browse/CAY-1354
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Core Library
>    Affects Versions: 3.1M1
>            Reporter: Evgeny Ryabitskiy
>            Assignee: Evgeny Ryabitskiy
>            Priority: Critical
>             Fix For: 3.1M1
>
>         Attachments: CAY-1354.patch, CAY-1354_TEST.patch, ReturnTypesMappingTest.java
>
>
>  By default every SQL type is mapped to some Java type by modeler.
> I am expecting same behavior in common DataRow queries (without ORM).
> But in fact half of types are not mapped correctly....
> Attached JUnit test can to explain problem with more details...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.