Results of multiple select statements in IMPORT truncated
Details
| Detail name | Value |
|---|---|
| Changelog Number | 7036 |
| Type | Bug |
| Status | Resolved |
| Affected Versions | Exasol 6.1.0, EXASOL 6.0.9 |
| Fix Versions | Exasol 6.0.14, Exasol 6.1.2 |
| Resolution Date | 2019-02-01 |
Background
Starting with Exasol 6.0.9, IMPORT from oracle supports multiple remote statements for parallelism (see EXASOL-2272)
Problem
When executing such an import and data types do not match across all statements, the imported string data may get truncated without error/warning.
Example:
import into t32 from ORA at EXADATA_ORA STATEMENT 'SELECT ''P0'' AS "PARTI" FROM DUAL' STATEMENT 'SELECT ''P10'' AS "PARTI" FROM DUAL';
The resulting string data may get truncated:
| PARTI |
|---|
| P0 |
| P1 |
when the expected correct result would have been:
| PARTI |
|---|
| P0 |
| P10 |
Workaround:
A workaround is to re-order the statements such that the statement with largest result row comes first:
import into t32 from ORA at EXADATA_ORA
STATEMENT 'SELECT' 'P10' 'AS "PARTI" FROM "MY_SCHEMA" "MY_TABLE" PARTITION ("P10")'
STATEMENT 'SELECT' 'P0' 'AS "PARTI" FROM "MY_SCHEMA". "MY_TABLE" PARTITION ("P0")'
;
in this case, the result row set is not truncated (remember: order of result set is not assured)