DB2 Import with pipe delimeter and codebase is japanese script

1.1k views Asked by At

I m using following import command for importing japanese script into db2 table.

Import from './data/product attributes to be uploaded_20120124.txt' of del modified by coldel| CODEPAGE=932 INSERT INTO TEMP_UPLOAD_PRODUCT_ATTRIBUTES (ProductGuid,CATEGORY_GUID,LOCALEGUID,REALMGUID,CATCHING_PHRASE,GENERIC_NAME,INGREDIENTS,QUANTITY,DOSE,NUTIRITION_FACTS,PRODUCT_DESCRIPTION,RECOMMENDED_FOR,PROMOTION_MSG,MESSAGE)

I get the message as:

SQL3017N A delimiter is not valid or is used more than once.

When checking the message code definition, it seems pipe may not be valid delimeter. It also says: For UTF-8 data, the valid range for the delimiters is 0x00 - 0x7F inclusive

Where do I find the mapping of the hex and symbol? what are the valid delimetrs in this case? or is there any other issue?

Please advice.

Thanks,

2

There are 2 answers

1
Fred Sobotka On

Assuming that your input data is properly delimited, you should be able to import a pipe-delimited file by specifying COLDEL0x7C as a modifier for the IMPORT command.

0
beetri On

It worked after changing delimeter to TAB Japanese codepages only allow delimiters in the range 0x00 to 0x3F, | is 0x7C tab is 0x09