db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mamta A. Satoor (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-2879) CREATE TABLE AS <subquery> does not maintain the collation for character types.
Date Mon, 02 Jul 2007 16:26:04 GMT

    [ https://issues.apache.org/jira/browse/DERBY-2879?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509607

Mamta A. Satoor commented on DERBY-2879:

With the revision 552531, changes have been committed for this Jira entry and a minor cleanup
is done. The commit comments as copied below has the details. Will soon commit this change
in Derby codeline.


Derby currently requires all the character columns in a table to have the same collation as
the collation of the schema in
which the table is getting defined. In order to implement this behavior, CreateTableNods's
bind method will check the
collation of it's character columns against the schema's collation and if there is a mismatch,
an exception will be thrown.

In addition, this patch does minor cleanup. The string constants for the 2 collation types
in Derby were declared in both
StringDataValue.java and Property.java I have removed it from StringDataValue so we don't
have duplicate constants.

> CREATE TABLE AS <subquery> does not maintain the collation for character types.
> -------------------------------------------------------------------------------
>                 Key: DERBY-2879
>                 URL: https://issues.apache.org/jira/browse/DERBY-2879
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions:,,
>            Reporter: Daniel John Debrunner
>            Assignee: Mamta A. Satoor
>            Priority: Critical
> create table t as select tablename from sys.systables with no data;
> This creates a column TABLENAME with collation based upon the user schema, but the type
of  sys.systables.tablename has collation UCS_BASIC.
> The required behaviour should be verified with the SQL standard (11.3 SR6), but since
collation is an attribute of a type it seems logical that the collation is maintained by the
> Fixing this to keep the collation of the system column will cause problems though as
there would be no way to recreate this table through a regular create table, say if the schema
is dumped and recreated using ddlutils.
> I think this is critical as fixing it after a release would lead to a change in behaviour
for applications.

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

View raw message