Hi All,
Not sure what I'm doing wrong but I'm trying to load a thorn (þ) delimited file. Here is a sample record
"field1"þ"field2"þ"field3"þ"field4"þ"field5"þ"field6"þ"field7"þ"field8"þ"field9"þ"field10"þ"field11"þ"field12"þ"field13"þ"field14"þ"field15"
Multiload script follows :
.logtable test.testtbl_log; .logon 192.168.201.133/dbc,xxxxxxxxxx; drop table test.testtbl_et; drop table test.testtbl_ut; drop table test.testtbl_uv; drop table test.testtbl_wt; .begin import mload tables test.testtbl SESSIONS 20; .layout InputFile_layout; .field DateStr * VARCHAR(255) ; .field Event * VARCHAR(255) ; .field ToolbarId * VARCHAR(255) ; .field UserId * VARCHAR(255) ; .field Username * VARCHAR(255) ; .field UserEmail * VARCHAR(255) ; .field FirstName * VARCHAR(255) ; .field LastName * VARCHAR(255) ; .field Browser * VARCHAR(255) ; .field BrowserVersion * VARCHAR(255) ; .field OS * VARCHAR(255) ; .field ToolbarVersion * VARCHAR(255) ; .field SearchSource * VARCHAR(4000) ; .field ClickType * VARCHAR(4000) ; .field ClickUrl * VARCHAR(4000) ; .dml label TableName_InsertDML; insert into test.testtbl ( DateStr ,Event ,ToolbarId ,UserId ,Username ,UserEmail ,FirstName ,LastName ,Browser ,BrowserVersion ,OS ,ToolbarVersion ,SearchSource ,ClickType ,ClickUrl ) values ( trim(both from trim(both '"' from :DateStr ) ) ,trim(both from trim(both '"' from :Event ) ) ,trim(both from trim(both '"' from :ToolbarId ) ) ,trim(both from trim(both '"' from :UserId ) ) ,trim(both from trim(both '"' from :Username ) ) ,trim(both from trim(both '"' from :UserEmail ) ) ,trim(both from trim(both '"' from :FirstName ) ) ,trim(both from trim(both '"' from :LastName ) ) ,trim(both from trim(both '"' from :Browser ) ) ,trim(both from trim(both '"' from :BrowserVersion) ) ,trim(both from trim(both '"' from :OS ) ) ,trim(both from trim(both '"' from :ToolbarVersion) ) ,trim(both from trim(both '"' from :SearchSource ) ) ,trim(both from trim(both '"' from :ClickType ) ) ,trim(both from trim(both '"' from :ClickUrl ) ) ); .import infile testtbl_all.csv format vartext '00FE'xc display errors layout InputFile_Layout apply TableName_InsertDML; .end mload; .logoff;
I get the following error:
"field1"├╛"field2"├╛"field3"├╛"field4"├╛"field5"├╛"field6"├╛"field7"├╛"field8"├╛"field9"├╛"field10"├╛"field11"├╛"field12"├╛"field13"├╛"field14"├╛"field15" **** 14:03:52 UTY4014 Access module error '61' received during 'pmReadDDparse' operation: 'Warning, too few columns !ERROR! Delimited Data Parsing error: Too few columns in row 1'
Forums: