You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ddlutils-dev@db.apache.org by "Thomas Dudziak (JIRA)" <ji...@apache.org> on 2007/02/08 08:23:05 UTC
[jira] Resolved: (DDLUTILS-155) type cast to 'LONG VARCHAR' fails
[ https://issues.apache.org/jira/browse/DDLUTILS-155?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Thomas Dudziak resolved DDLUTILS-155.
-------------------------------------
Resolution: Fixed
Fix Version/s: 1.0
I've changed this to use the CAST function instead (which has no problems with "LONG VARCHAR").
> type cast to 'LONG VARCHAR' fails
> ---------------------------------
>
> Key: DDLUTILS-155
> URL: https://issues.apache.org/jira/browse/DDLUTILS-155
> Project: DdlUtils
> Issue Type: Bug
> Components: Core - DB2
> Environment: DB2 v8 on Windows
> Reporter: Stefan Huber
> Assigned To: Thomas Dudziak
> Priority: Minor
> Fix For: 1.0
>
>
> I tried to update an existing database. Within the update the type of a column changed from CLOB to LONG VARCHAR.
> This procedure failed because the SqlBuilder created the following statement
> INSERT INTO LOGMESSAGES_ (MESSAGEID,MESSAGETEXT)
> SELECT MESSAGEID,LONG VARCHAR (MESSAGETEXT) FROM LOGMESSAGES
> which does not work on any database.
> I resolved this effect by simply replacing the blank in 'LONG VARCHAR' with an underscore (method Db2Builder.writeCastExpression(...)).
> The resulting statement contains a valid cast expression.
> INSERT INTO LOGMESSAGES_ (MESSAGEID,MESSAGETEXT)
> SELECT MESSAGEID,LONG_VARCHAR (MESSAGETEXT) FROM LOGMESSAGES
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.