When trying to import from and Excel sheet into a table using Toads Database menu | Import | Import table data, it gives the error:
ORA-01400: Cannot insert NULL into (schema.table.column)
Run the Import Table Data. The set up for the wizard works fine, and the data shows up correctly in the preview. But in the end when trying to execute the import, it errors out and the first row of data is not imported.
Sample Table:
CREATE TABLE SAMPLE_TYPE
(
COL1_ID VARCHAR2(1 BYTE) NOT NULL,
COL2_TYPE_DSC VARCHAR2(15 BYTE)
);
Sample Data:
A Actual
B Budget
But, in the excel file, if the data in the first row is changed from something like A to AA, the import works without any errors, and ends up inserting a single A instead of double. It does not prompt to trim the imported value.
Conflict with the NOT NULL setting.
WORKAROUND 1:
Use double in the first row of the inserted data in the Excel file.
Sample Data: when the table is created with COL1_ID VARCHAR2(1 BYTE) NOT NULL,
AA Actual
B Budget
WORKAROUND 2:
Install and use Toad for Oracle 9.7.2.
This has been found to be an issue in Toad 10 and some older versions of Toad, but not Toad 9.7.2.
STATUS:
Issue fixed in version 10.5. The latest version of Toad for Oracle can be downloaded here.
© 2021 Quest Software Inc. ALL RIGHTS RESERVED. Feedback Terms of Use Privacy