One Star

How to read file having \x01 delimited

Hi,
I am trying to read files having \x01 delimited but I am getting error as invalid excape. Please help.
THank you.
4 REPLIES
Moderator

Re: How to read file having \x01 delimited

Hi,
Could you please show us some fragment of your input file so that we can know your situation more precisely.
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
Seventeen Stars

Re: How to read file having \x01 delimited

The delimiter in the tFileInputDelimited as a Java String. What ever is necessary to declare your delimiter as Java String is the right thing to setup the component.
Use that as field delimiter:
String.valueOf(Character.toChars(01))
One Star

Re: How to read file having \x01 delimited

Hi,
Following are some sample records of the file -
50882013-05-28114
50882013-06-11135
50882013-06-26175
50882013-07-01141
50882013-07-02181
50882013-07-0311
50882013-07-03125
50882013-07-03131
50882013-07-03171
50882013-07-0571
"\x01" is an invisible delimiter which cant be typed from keyboad. this file is generated by Ab Initio and we are trying to read this file but we are not able to. Here is the file format -
record
utf8 string("\x01", maximum_length=4) whse /*VARCHAR(4)*/;
date("YYYY-MM-DD")("\x01") date_time /*DATE*/;
decimal("\x01") date_hours /*INTEGER*/;
decimal("\x01") cartoncount /*INTEGER NOT NULL*/;
string(1) newline = "\n";
end
Please help me on this.
Thanks,
Madhusudan
Five Stars

Re: How to read file having \x01 delimited

can you show us hexadecimal view of record,