commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew DeMaria (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (CONFIGURATION-637) Oracle invalid idenitifer when using a resevered keyword for column name
Date Thu, 28 Jul 2016 16:57:20 GMT

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

Andrew DeMaria closed CONFIGURATION-637.
----------------------------------------
    Resolution: Invalid

> Oracle invalid idenitifer when using a resevered keyword for column name
> ------------------------------------------------------------------------
>
>                 Key: CONFIGURATION-637
>                 URL: https://issues.apache.org/jira/browse/CONFIGURATION-637
>             Project: Commons Configuration
>          Issue Type: Bug
>    Affects Versions: 2.0
>         Environment: Oracle, Java 1.8
>            Reporter: Andrew DeMaria
>            Priority: Minor
>
> I have the following create table for oracle to store configs. Notice that the "scope"
column name is properly escaped:
> {noformat}
> create table PROPERTY_CONTROL (
>   "scope" VARCHAR2(32),
>   "key" VARCHAR2(128),
>   "value" VARCHAR2(512),
>   CONSTRAINT property_control_pk PRIMARY KEY ("scope", "key")
> );
> {noformat}
> However, this causes the following stack trace (slightly modified for sensitive class
names):
> {noformat}
> java.sql.SQLSyntaxErrorException: ORA-00904: "SCOPE": invalid identifier
> 	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:457)
> 	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:400)
> 	at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:926)
> 	at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:476)
> 	at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:200)
> 	at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:543)
> 	at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:238)
> 	at oracle.jdbc.driver.T4CPreparedStatement.executeForDescribe(T4CPreparedStatement.java:1244)
> 	at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1492)
> 	at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1710)
> 	at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:4372)
> 	at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:4453)
> 	at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(OraclePreparedStatementWrapper.java:6270)
> 	at com.zaxxer.hikari.proxy.PreparedStatementProxy.executeQuery(PreparedStatementProxy.java:52)
> 	at com.zaxxer.hikari.proxy.HikariPreparedStatementProxy.executeQuery(HikariPreparedStatementProxy.java)
> 	at org.apache.commons.configuration2.DatabaseConfiguration$JdbcOperation.openResultSet(DatabaseConfiguration.java:847)
> 	at org.apache.commons.configuration2.DatabaseConfiguration$4.performOperation(DatabaseConfiguration.java:487)
> 	at org.apache.commons.configuration2.DatabaseConfiguration$4.performOperation(DatabaseConfiguration.java:483)
> 	at org.apache.commons.configuration2.DatabaseConfiguration$JdbcOperation.execute(DatabaseConfiguration.java:742)
> 	at org.apache.commons.configuration2.DatabaseConfiguration.containsKeyInternal(DatabaseConfiguration.java:494)
> 	at org.apache.commons.configuration2.AbstractConfiguration.containsKey(AbstractConfiguration.java:1086)
> 	at org.apache.commons.configuration2.CompositeConfiguration.containsKeyInternal(CompositeConfiguration.java:374)
> 	at org.apache.commons.configuration2.AbstractConfiguration.containsKey(AbstractConfiguration.java:1086)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message