db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rick Hillegas (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (DERBY-3341) TABLE FUNCTION returning CHAR values does not return a correct value if the Java ResultSet class returns a value less than the length of the defined CHAR.
Date Tue, 10 Jun 2008 21:01:46 GMT

     [ https://issues.apache.org/jira/browse/DERBY-3341?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Rick Hillegas resolved DERBY-3341.
----------------------------------

    Resolution: Fixed

I believe that this issue can be closed. The odd parameter passing between the compiler and
the execution engine was cleaned up by Knut in his patch to DERBY-3616. I think there is an
outstanding design issue of where we should coerce values coming out of the Java domain. What
is implemented is coercion in the Derby result set which wraps  the Java ResultSet. Another
proposal is to perform the coercion via casts above the wrapping Derby result set. If someone
wants to pursue that, I think the effort merits its own JIRA and discussion.

> TABLE FUNCTION returning CHAR values does not return a correct value if the Java ResultSet
class returns a value less than the length of the defined CHAR.
> ----------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-3341
>                 URL: https://issues.apache.org/jira/browse/DERBY-3341
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Attachments: derby-3341-01-coerce.diff, derby-3341-01-da-coerceWithTests.diff,
derby-3341-02-aa-refGuide.diff, derby_3341_test.txt, rrefcreatefunctionstatement.html
>
>
> Defining a column in the returned type as CHAR(10) requires that the returned value be
of length 10 characters.
> Defining a table function with a return type of:
>    returns TABLE  column0 char( 10 ), column1 char( 10 ))
> seems to just return whatever the Java ResultSet implementation handed it.
> My guess this is true for all variable length types, no casting of the value occurs when
it is returned to the SQL domain.
> Java single value functions and procedure out parameters do perform any required casting
to ensure the value is of the declared type.

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


Mime
View raw message