Friday, August 7, 2015

[SAP][ODBC Driver]Non-space text found after ending quote


I have encountered below error during data import into HANA Dynamic Tiering

* 403: internal error: [SAP][ODBC Driver]Non-space text found after ending quote
-- (dblib/db_RecScanner.cxx 2657) SQLSTATE: HY000


I found that data has quotes (“) which is causing the issue. But didn’t find any forum/link related to this error in HANA DT or solution.

At this situation SLT can help, I have used SLT to load the data and was able to load successfully.

During research I found that few users encountered same issue during the data import into SYBASE
They propose below recommendations

- Remove quotes from all values in data file
- TURN OFF the QUOTES as QUOTES ON is default.

Refer below link for more info for SYBASE error
https://scn.sap.com/thread/3638327

Other possible errors you may encounter:

* 403: internal error: [SAP][ODBC Driver]Cannot convert PatKey to a integer(10) (column EMPLOYEE_ID) SQLSTATE: HY00

Possible solution: Please choose appropriate data type.

Regards
Satishbabu Gunukula, Oracle ACE
http://www.oracleracexpert.com 

2: general error: Table does not exist SQLSTATE: HY000


I was importing data into HANA Dynamic Tiering and encountered below error.

* 2: general error: Table does not exist SQLSTATE: HY000

You will see this error if TABLE NAME is wrong. I have verified that table exists in the database but still see same issue and I have verified the syntax of the control file and everything looks good.

IMPORT DATA INTO TABLE "dtuser"."employee" FROM '/hana/shared/DT/HDB00/work/employee.txt'
RECORD DELIMITED BY '\n'
FIELD DELIMITED BY '|'
OPTIONALLY ENCLOSED BY '"'
ERROR LOG '/hana/shared/DT/HDB00/work/employee.log'

I see that user and table name is in lower case. I have modified the control file to use upper case for user/ table name and I was able to IMPORT successfully.

Other possible errors you may encounter:  
  • 2: general error: Cannot open the file, /hana/shared/DT/HDB00/work/employee.txt SQLSTATE: HY000
Possible solution: The file name is wrong or path may be in correct. You need to correct the same 
  • 2: general error: Cannot open Control file, /hana/shared/DT/HDB00/work/employee.ctl
Possible solution: The control file name is wrong or control file path may be incorrect

Regards
Satishbabu Gunukula, Oracle ACE
http://www.oracleracexpert.com