Fixed length

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
reddy12
Participant
Posts: 99
Joined: Tue Aug 08, 2006 9:34 pm

Fixed length

Post by reddy12 »

Hi all
Thanks all of you guys and DSXchange.

I need to create fixed length flat file.I am getting this error.I selected record length is fixed.how can i resolve this problem Please give me suggestion.

Sequentialfile1: Error when checking operator: "record_length=fixed" (no length given) and record field format is variable-length. The first variable-length field is "ST_NAME".

Thanks
Reddy.
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Why dont you start by telling us how you set up your job?
Did you provide the correct lengths of each field under the column's tab in the sequential file stage?
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
reddy12
Participant
Posts: 99
Joined: Tue Aug 08, 2006 9:34 pm

Post by reddy12 »

I am creating a flat file(Target).my data is like below.Like this the job is working.
"aaa","bbbb","2005-01-01 00:00:00"," ","2005-03-03 00:00:00"

But I need fixed length and without quotes and comma.
Ex:
aaa bbbb 2005-01-01 00:00:00 2005-03-03 00:00:00

I removed comma and quotes in properties of sequential file but my data is coming like below.i need spaces betwen the fields

aaabbbb2005-01-01 00:00:00 2005-03-03 00:00:00


DSguru2B wrote:Why dont you start by telling us how you set up your job?
Did you provide the correct lengths of each field under the column's tab in the sequential file stage?
reddy12
Participant
Posts: 99
Joined: Tue Aug 08, 2006 9:34 pm

Post by reddy12 »

I am creating a flat file(Target).my data is like below.Like this the job is working.
"aaa","bbbb","2005-01-01 00:00:00"," ","2005-03-03 00:00:00"

But I need fixed length and without quotes and comma.
Ex:
aaa bbbb 2005-01-01 00:00:00 2005-03-03 00:00:00

I removed comma and quotes in properties of sequential file but my data is coming like below.i need spaces betwen the fields

aaabbbb2005-01-01 00:00:00 2005-03-03 00:00:00
DSguru2B wrote:Why dont you start by telling us how you set up your job?
Did you provide the correct lengths of each field under the column's tab in the sequential file stage?
[/quote]
pradeepleon
Participant
Posts: 32
Joined: Fri Dec 02, 2005 10:44 pm
Location: Chicago,IL

Post by pradeepleon »

You need to set a delimiter.....check on that part.
Thanks,
Pradeep

(Ten Hugs And Nine KisseS - THANKS)......is that true?

In GOD we trust,for all others we take cash.
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Read the sequential file as a delimited file and then load it to a fixed width file. This will be much better than manually going in and removing the delimiters.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
Post Reply