Page 1 of 1

Compress Sequential File

Posted: Tue Feb 16, 2010 7:50 pm
by Magesh_bala
Hi All,
Can I use the COmpress stage for Sequential file? If yes please let me know what should be the Output columns for it?

Thanks
Magesh

Posted: Tue Feb 16, 2010 10:25 pm
by chulett
No. It (and the companion Expand Stage) are all about data sets. Now, that doesn't mean you can't "compress" a sequential file, you'd just have to do it with a singleton call to your O/S after creating it.

Posted: Tue Feb 16, 2010 11:05 pm
by Magesh_bala
How can I gzip the Sequential files using Datastage, Do we have any stage to do?

Posted: Tue Feb 16, 2010 11:10 pm
by ray.wurlod
The Compress stage can compress/gzip a data stream. What you do with it after that is up to you.

Posted: Tue Feb 16, 2010 11:43 pm
by ray.wurlod
You need to execute in sequential mode to compress into a single archive. But you can certainly have a Sequential File stage downstream of a Compress stage.

Posted: Tue Feb 16, 2010 11:58 pm
by Magesh_bala
I am sry, If am asking the same question again.

I need to gzip the Sequential files, When I use the Compress stage I am getting an error

"Error when checking operator: Could not find input field "FT_ACCOUNT_KEY".

How do i overcome this problem? In my Input I have 21 column what should be my Output columns?

Regards
Magesh

Posted: Wed Feb 17, 2010 1:00 am
by ray.wurlod
You will need 21 output columns.

Posted: Wed Feb 17, 2010 7:46 am
by ArndW
I wouldn't use the compress stage for this. Just use a sequential output stage and add the command "gzip -i" to it . I'm not at a DataStage computer now, but when I do I'll send the exact syntax I use.

Posted: Wed Feb 17, 2010 10:14 am
by ArndW
In the sequential file stage, just enter "bzip2 -c" to compress using bzip2, other commands have slightly differing sysntax to take their input from stdind.