Use quoted TABLE names for JDBC IMPORT/EXPORT

Details

Detail name Value
Changelog Number 4652
Type Bug
Status Resolved
Affected Versions EXASOL 6.0.0, EXASolution 5.0.0
Fix Versions EXASOL 6.0.2
Resolution Date 2017-06-02

Previously, the TABLE name option of a JDBC IMPORT/EXPORT statement was never quoted when executing a statement on the specified JDBC data source. Now, the TABLE name will be quoted if it is not already all upper case.

Previously, the statement

IMPORT <...> FROM JDBC AT <...> TABLE "My_Table";

would generate a query similar to the following, which would be executed on the JDBC data source. If the table name is case-sensitive in the JDBC data source, this may lead to an error.

SELECT <columns> FROM My_Table; -- Likely changed to MY_TABLE by the data source

Now, the generated query would be similar to the following, which is the expected behavior.

SELECT <columns> FROM "My_Table";

The behavior for statements with unquoted or all upper-case TABLE names remains unchanged.

IMPORT <...> FROM JDBC AT <...> TABLE My_Table;
IMPORT <...> FROM JDBC AT <...> TABLE "MY_TABLE";

result in

SELECT <columns> FROM MY_TABLE;

as before.

Changed behavior

Previously, the TABLE name option of a JDBC IMPORT/EXPORT statement was never quoted when executing a statement on the specified JDBC data source. Now, the TABLE name will be quoted if it is not already all upper case, which is the case if quotes were using around the TABLE name in the IMPORT/EXPORT command.