You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Daniel John Debrunner (JIRA)" <de...@db.apache.org> on 2006/09/18 22:57:22 UTC

[jira] Created: (DERBY-1863) SQL NULL always represented as zero when mapping an INTEGER column to a Java int or Integer field using a EOD query object extended from BaseQuery

SQL NULL always represented as zero when mapping an INTEGER column to a Java int or Integer field using a EOD query object extended from BaseQuery
--------------------------------------------------------------------------------------------------------------------------------------------------

                 Key: DERBY-1863
                 URL: http://issues.apache.org/jira/browse/DERBY-1863
             Project: Derby
          Issue Type: Bug
          Components: JDBC
    Affects Versions: 10.2.1.0, 10.3.0.0
            Reporter: Daniel John Debrunner


SQL INTEGER column mapped to a Java primitive int field resulted in the filed set to zero when the SQL value was NULL.
This means there is no way to tell if the field was NULL or not. I was expecting some error, either at "mapping" time or at exection time.

SQL INTEGER column mapped to a Java java.lang.Integer field resulted in the filed set to zero when the SQL value was NULL.
Was expecting the field to be set to Java null. Note for VARCHAR columns mapped to a String field, the result is Java null when the SQL value is NULL.

JDBC 4.0 spec seems silent on the expected behaviour for @Select queries and the column mapping when the SQL value is NULL.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (DERBY-1863) SQL NULL always represented as zero when mapping an INTEGER column to a Java int or Integer field using a EOD query object extended from BaseQuery

Posted by "Daniel John Debrunner (JIRA)" <de...@db.apache.org>.
     [ http://issues.apache.org/jira/browse/DERBY-1863?page=all ]

Daniel John Debrunner updated DERBY-1863:
-----------------------------------------

    Environment: Mustang b98

> SQL NULL always represented as zero when mapping an INTEGER column to a Java int or Integer field using a EOD query object extended from BaseQuery
> --------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-1863
>                 URL: http://issues.apache.org/jira/browse/DERBY-1863
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.1.0, 10.3.0.0
>         Environment: Mustang b98
>            Reporter: Daniel John Debrunner
>
> SQL INTEGER column mapped to a Java primitive int field resulted in the filed set to zero when the SQL value was NULL.
> This means there is no way to tell if the field was NULL or not. I was expecting some error, either at "mapping" time or at exection time.
> SQL INTEGER column mapped to a Java java.lang.Integer field resulted in the filed set to zero when the SQL value was NULL.
> Was expecting the field to be set to Java null. Note for VARCHAR columns mapped to a String field, the result is Java null when the SQL value is NULL.
> JDBC 4.0 spec seems silent on the expected behaviour for @Select queries and the column mapping when the SQL value is NULL.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (DERBY-1863) SQL NULL always represented as zero when mapping an INTEGER column to a Java int or Integer field using a EOD query object extended from BaseQuery

Posted by "Daniel John Debrunner (JIRA)" <de...@db.apache.org>.
     [ http://issues.apache.org/jira/browse/DERBY-1863?page=all ]

Daniel John Debrunner closed DERBY-1863.
----------------------------------------

    Resolution: Won't Fix

EoD is being dropped from JDBC 4.

> SQL NULL always represented as zero when mapping an INTEGER column to a Java int or Integer field using a EOD query object extended from BaseQuery
> --------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-1863
>                 URL: http://issues.apache.org/jira/browse/DERBY-1863
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.1.6, 10.3.0.0
>         Environment: Mustang b98
>            Reporter: Daniel John Debrunner
>
> SQL INTEGER column mapped to a Java primitive int field resulted in the filed set to zero when the SQL value was NULL.
> This means there is no way to tell if the field was NULL or not. I was expecting some error, either at "mapping" time or at exection time.
> SQL INTEGER column mapped to a Java java.lang.Integer field resulted in the filed set to zero when the SQL value was NULL.
> Was expecting the field to be set to Java null. Note for VARCHAR columns mapped to a String field, the result is Java null when the SQL value is NULL.
> JDBC 4.0 spec seems silent on the expected behaviour for @Select queries and the column mapping when the SQL value is NULL.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira