Page 1 of 1

Problem viewing the sequential file

Posted: Thu Jan 11, 2007 2:30 pm
by sshettar
Hi All,

Well i have this job where i get the sequential file which is created in the server job . this file has delimiter as , and quotes as " on the server side
but when i try to view this file in the parallel job with the delimiter as comma and quotes as double i see that few of the fields as displayed with the double quotes .
how do i get rid of these double quotes here in the pararrel job?

Could somebody plz help me with this issue

Thanks in advance

Re: Problem viewing the sequential file

Posted: Thu Jan 11, 2007 2:36 pm
by I_Server_Whale
sshettar wrote: but when i try to view this file in the parallel job with the delimiter as comma and quotes as double i see that few of the fields as displayed with the double quotes .
What are the datatypes of those few fields?

Posted: Thu Jan 11, 2007 2:37 pm
by roy
Hi,
How do you see this info with a regular text editor outside DS?

Posted: Thu Jan 11, 2007 2:38 pm
by sshettar
All the fields are of data type are Varchar

Posted: Thu Jan 11, 2007 4:27 pm
by narasimha
Try reading it using a hex editor like UltraEdit or xvi32 and check if you see something different.

We had a similar problem...

Posted: Thu Jan 11, 2007 5:46 pm
by jdmiceli
Hi all,

We had a problem similar to this. The main issue was that our data could legitimately hold quotes as part of the field. What we did was to take Ken Bland's advice and make our delimiter the pipe symbol ( | ) and then change the text delimiter on the file to be three zeroes ( 000 ). He also suggested checking the box that makes the first row the field names. When we did this, all our problems of this annoying ilk went away.

Give it a shot!

Bestest,

clarification

Posted: Thu Jan 11, 2007 5:50 pm
by jdmiceli
Just to allay confusion before it starts:

I meant to say that the delimiter is the pipe symbol ( | ) and the quote character would be three zeroes ( 000 ). Just in case you need to know where these settings are, they are found in the Sequential file stage --> Inputs --> Format. The check box for 'First line is column names' is on the left, and the other two fields are on the right.

Hope this helps!

Posted: Thu Jan 11, 2007 6:05 pm
by kcbland
Do the data fields contain double double-quotation marks? Physically view the file outside of datastage and confirm.

Re: clarification

Posted: Thu Jan 11, 2007 7:37 pm
by chulett
jdmiceli wrote:Just to allay confusion before it starts:

I meant to say that the delimiter is the pipe symbol ( | ) and the quote character would be three zeroes ( 000 ).
And just to further allay confusion for anyone who's never played with those settings before - setting the quote character to three zeroes doesn't mean it will use three zeros. It is the secret signal to DataStage to not use (or expect) any quote characters in the file. :wink:

Any quotes, if present, would then be treated as part of the data.

Posted: Thu Jan 11, 2007 7:49 pm
by kcbland
And to clarify chuletts allaying of confusion, 000 is the ASCII decimal value for NULL. In the good old days of serial communications, you would use a keyboard to type values over the serial line. When you needed to send a high or low ASCII character, you would hold down your ALT key and type in the 3-digit ASCII value of the character you want. We could sent bell characters (ding) that way, hangups, whatever.

To get a capital A, hold down your ALT key and type 065 on your keyboard and then release the ALT key. Viola, a letter A pops up. You can do this today to get any low/high-ASCII character typed anywhere.

Posted: Thu Jan 11, 2007 8:33 pm
by chulett
I left that part for you, Ken. :lol:

(ding)

Posted: Thu Jan 11, 2007 9:11 pm
by ray.wurlod
000 is the ASCII decimal value for NUL. This is not the same thing as NULL, which is represented differently by different vendors. For example, within DataStage an out-of-band NULL is represnted by -128.

0000 is the Unicode decimal value for NUL.

You can also specify non-printing delimiter or quote characters using a three digit decimal ASCII code or a four digit hexadecimal Unicode code.