[OS-JIRA] Created: (CAY-119) 1.1M5, date, prefetch and MS SQL Server

From: jir..bjectstyle.org
Date: Fri Apr 23 2004 - 03:59:46 EDT

  • Next message: Matt Kerr: "missing support for db _PROPERTY columns ?"

    Message:

      A new issue has been created in JIRA.

    ---------------------------------------------------------------------
    View the issue:

      http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-119

    Here is an overview of the issue:
    ---------------------------------------------------------------------
            Key: CAY-119
        Summary: 1.1M5, date, prefetch and MS SQL Server
           Type: Bug

         Status: Assigned
       Priority: Major

        Project: Cayenne
     Components:
                 Cayenne Core Library
       Versions:
                 1.1 [DEV]

       Assignee: Andrus Adamchik
       Reporter: Tore Halset

        Created: Fri, 23 Apr 2004 3:58 AM
        Updated: Fri, 23 Apr 2004 3:58 AM
    Environment: 1.1M5 and MS SQL Server

    Description:
    I got a strange error when upgrading from 1.0.6 to 1.1-M5.

    The relation is ORDER<->>ORDER_PRODUCT. One order can have multiple order products, but every order product has only one order. I do a query on order based on an order_date and prefetch all the related order products.

    This did work before upgrading to 1.1-M5. It fails on MS SQL Server, but works ok on PostgreSQL. It works on MS SQL Server if I remove the order_date from the query *or* remove the prefetch.

    This is the stacktrace:
    java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Unable to determine the type of the specified object.
            at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source)
            at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)
            at com.microsoft.jdbc.base.BasePreparedStatement.setObject(Unknown Source)
            at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.setObject(WrappedPreparedStatement.java:625)
            at org.objectstyle.cayenne.access.trans.QueryAssembler.initStatement(QueryAssembler.java:160)
            at org.objectstyle.cayenne.access.trans.QueryAssembler.createStatement(QueryAssembler.java:138)
            at org.objectstyle.cayenne.access.DataNode.runSelect(DataNode.java:361)
            at org.objectstyle.cayenne.access.DataNode.performQueries(DataNode.java:322)
            at org.objectstyle.cayenne.access.DataDomain.performQueries(DataDomain.java:662)
            at org.objectstyle.cayenne.access.DataContext.performQueries(DataContext.java:1359)
            at org.objectstyle.cayenne.access.Transaction.performQueries(Transaction.java:176)
            at org.objectstyle.cayenne.access.DataContext.performQueries(DataContext.java:1282)
            at org.objectstyle.cayenne.access.DataContext.performQuery(DataContext.java:1248)

    ---------------------------------------------------------------------
    JIRA INFORMATION:
    This message is automatically generated by JIRA.

    If you think it was sent incorrectly contact one of the administrators:
       http://objectstyle.org/jira/secure/Administrators.jspa

    If you want more information on JIRA, or have a bug to report see:
       http://www.atlassian.com/software/jira



    This archive was generated by hypermail 2.0.0 : Fri Apr 23 2004 - 03:59:48 EDT