Help needed geting output strem from custom wrapped stage

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
banactp
Participant
Posts: 52
Joined: Tue Feb 22, 2005 2:55 pm

Help needed geting output strem from custom wrapped stage

Post by banactp »

Where is the "frustrated" emoticon when I need it?

I have a parallel job consisting of two stages. The first stage is a custom wrapped stage. On the Wrapped\Output tab of the stage properties in Manager I have declared one output link, attached to the standard output stream. The wrapped code, written only for testing purposes, is quite simple:

Code: Select all

int main( int argc, char **argv ) {
  String cmdline = "Command line: ";
  int j;

  for ( j=0 ; j < (argc-1) ; j++ ) {
    cmdline += String(argv[j]) + " ";
  }
  cmdline += argv[j];

  return( puts((const char*)(cmdline)) );
}
As you can see, the wrapped code simply takes its input arguments, concatenates them, and puts the resulting string to standard output. There is no difficulty running the compiled code from the command line.

In my job design, I have the output of this custom stage linked to a sequential file stage. The intent was to direct the standard output stream produced by my custom stage to the file as proof of concept that one can utilize the output of a custom wrapped stage in a parallel job.

However, when I try to run this job, I get the following error:

Code: Select all

Sequential_File_Stage: Error when checking operator: Could not find input field "fromCustom".
"fromCustom" is the sole column name on the input to the sequential file stage. It's Varchar(2048). My guess is that this error indicates that DataStage is failing to connect to the output stream properly.

Can anyone please provide any insight as to what I am doing wrong? If I'm making an error, I suppose it's probably in the setup of the stage in Manager, but I'm out of ideas at this point. :(

TIA,

tpb
Post Reply