Hi, i'm executing a create table and insert records in flat text file but i found an error when insert string with blank spaces.
My connection is:
jdbc:csv:////tmp?csvfileExtension=ASC;_CSV_Header=false;emptyStringAsNull=false;
Create table SQL:
CREATE TABLE CLIENTES2(Company CHAR(2), CustomerNbr CHAR(9), AddressCode CHAR(3), Tel2 CHAR(15) NOT NULL DEFAULT '#TEL2 #', Fax CHAR(15), ContactName CHAR(30), Contry CHAR(3), CustFamily CHAR(3), Language CHAR(3), Currency
CHAR(3), DeftCarrAcc CHAR(20), DunsNo CHAR(10), SupplierNbr CHAR(10), DeftCarr CHAR(3), Account CHAR(3), CustServRep CHAR(3), XaCustomerNbr CHAR(10), IRSNumber CHAR(15), TaxCode1 CHAR(3), PaymentCode CHAR(3), DueDateCode CHAR(4), Comments CHAR(30), ShipToLocCde CHAR(20), CustStillNbr CHAR(10), _CSV_Separator char(0))
Insert SQL:
INSERT INTO CLIENTES2(Company,CustomerNbr,AddressCode,Tel2,Fax,ContactName,Contry,CustFamily,Language,Currency,DeftCarrAcc,DunsNo,SupplierNbr,DeftCarr,Account,CustServRep,XaCustomerNbr,IRSNumber,TaxCode1,PaymentCode,DueDateCode,Comments,ShipToLocCde,CustStillNbr) VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
VALUES: [01, 000475210, 999, null, , , , , 000, , , , , , 000, 000, , , 000, 000, 0000, , , ]
And the result in the text file is:
010004752109990000000000000000000
And the expected result is something similar to this:
01000475210999 000 000 0000000000000
What im missing in configuration for the driver truncate all the blank string with empty spaces?
Best regards.
|