I am working on Import from Statement and from here https://help.sap.com/viewer/4fe29514fd584807ac9f2a04f6754767/2.0.03/en-US/20f712e175191014907393741fadcb97.html we know that there are two ways using 1) csv file and using 2) control file.
I created a control file (saved as data.ctl) with below content -
IMPORT DATA INTO TABLE "SYSTEM"."EMPLOYEE" FROM '/usr/sap/HXE/HDB90/work/data.csv' RECORD DELIMITED BY '\n' FIELD DELIMITED BY ',' OPTIONALLY ENCLOSED BY '"' ERROR LOG '/usr/sap/HXE/HDB90/work/data.err'
whereas EMPLOYEE table is created using
Create COLUMN Table EMPLOYEE (ID integer, NAME varchar(20), DEPARTMENT varchar(20)) WITH SCHEMA FLEXIBILITY
I am successfully able to execute import from statement using
IMPORT FROM '/usr/sap/HXE/HDB90/work/data.ctl' WITH COLUMN LIST (ID, NAME, DEPARTMENT)
but I am trying to run it using below option -
IMPORT FROM '/usr/sap/HXE/HDB90/work/data.ctl' WITH COLUMN LIST (ID, NAME, DEPARTMENT) WITH SCHEMA FLEXIBILITY
but I am getting error as "feature not supported: SCHEMA FLEXIBILITY option is only for column table".
Note - I am able to use this option with schema flexibility on same table, while importing csv file using import from statement