db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@debrunners.com>
Subject Re: [PATCH] Derby-107, Phase I
Date Wed, 16 Feb 2005 18:27:40 GMT
Army wrote:
> 
> Based on discussion from this derby-dev list and on my understanding of
> the changes that are going to be required, I am proposing to submit the
> changes for Derby-107 (ODBC metadata support) in the following three
> phases.  I will include more details about the separate phases with each
> patch that I submit.
> 
> Note: By "SAFE" in the following list, I mean that the changes can be
> made and Derby will still fully adhere to the JDBC standard.
> 
> Phase I) Where it is SAFE to do so, cast CHAR columns to VARCHAR columns
> in the metadata result sets.

> 
> Attached is a patch for Phase I:
> "Where it is SAFE to do so, cast CHAR columns to VARCHAR columns in the
> metadata result sets."
> 


Just one comment that limiting REMARKS to 128 characters for
getProcedures is too limiting. Java method names with the complete
package name and possible signature can easily exceed 128 characters.
Maybe limit to the maximum VARCHAR length.




Dan.
> ------------------------------------------------------------------------
> 
> Index: java/engine/org/apache/derby/impl/jdbc/metadata.properties
> ===================================================================
> --- java/engine/org/apache/derby/impl/jdbc/metadata.properties	(revision 151101)
> +++ java/engine/org/apache/derby/impl/jdbc/metadata.properties	(working copy)
> @@ -24,11 +24,12 @@
>  # multiple methods, some of which could return a value and some not.
>  #
>  getProcedures=\
> -	SELECT '' AS PROCEDURE_CAT, SCHEMANAME AS PROCEDURE_SCHEM, \
> +	SELECT CAST ('' AS VARCHAR(128)) AS PROCEDURE_CAT, \
> +		SCHEMANAME AS PROCEDURE_SCHEM, \
>  	    ALIAS AS PROCEDURE_NAME, \
>  		CAST (NULL AS INT) AS RESERVED1, CAST (NULL AS INT) AS RESERVED2, \
>  	    CAST (NULL AS INT) AS RESERVED3, \
> -		JAVACLASSNAME||'.'|| ALIASINFO->getMethodName() AS REMARKS, \
> +		CAST ((JAVACLASSNAME||'.'|| ALIASINFO->getMethodName()) AS VARCHAR(128)) AS REMARKS,
\


Mime
View raw message