'##' Parameter

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
suresh_dsx
Participant
Posts: 160
Joined: Tue May 02, 2006 7:49 am

'##' Parameter

Post by suresh_dsx »

i am getting output from Sequential file stage like this
i am passing a parameter to the job is
'DD','RR',
It is working fine.

my output is like this
new_id= 900 dt_id beteen 1000 and 2000 or
new_id= 800 dt_id beteen 4000 and 6000

when i give like this
'DD','RR','##'
It is not returning any rows.How can i handle the job.
My job is
oracle stage --> transformer --> sequentail file
i am using seqential file. this is one not allow that character, i need to use any defalut values in that.

please give suggestions
Thanks
suresh_dsx
Participant
Posts: 160
Joined: Tue May 02, 2006 7:49 am

Post by suresh_dsx »

sorry not windows.
target file is storing in the unix directory.
narasimha
Charter Member
Charter Member
Posts: 1236
Joined: Fri Oct 22, 2004 8:59 am
Location: Staten Island, NY

Post by narasimha »

How and where are you passing these parameters?
Narasimha Kade

Finding answers is simple, all you need to do is come up with the correct questions.
suresh_dsx
Participant
Posts: 160
Joined: Tue May 02, 2006 7:49 am

Post by suresh_dsx »

Constraint: @INROWNUM = Cnt+1


Stage variable. IF @INROWNUM=1 then (id = ' : SourceRead.ID : ' and dt between ' : stdt : ' and ' : ednt: ')' else SrcFilter : ' or ' : '(id = ' : ID : ' and stdt between ' : ednt : ' and ' : mdot: ')'


i am passing this stage variable into column in the tranformer. i need to store this value in the sequenetial file stage..



if i give LIKE THIS parameter
'DD','BB',GG',EE',JJ',LL',NN','##'

the parameter is checking the corresponding data is there in the table. it is giving value. Thier is no '##' in the source table.

Is this is the reason not reading the values.

ho can i handle in the stage variable and also constraint in the job.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

suresh - if we take a step back, you are saying that when you use text values for a job parameter it works, but if you use two hash signs it does not work?

Since the hash mark, '#', gets interpreted by a UNIX shell to have a wildcard meaning and is also used in DataStage in some places to mark a parameter string you are perhaps getting issues due to this.

Does the stage variable derivation you listed use this parameter? What is the parameter name (could it be "ID")? Have you output the value of this stage variable into a sequential file or in the debugger to see if it is being set correctly there?
the parameter is checking the corresponding data is there in the table
. This doesn't match your design shown in the first post, where you have oracle->trans->seq shown.
I_Server_Whale
Premium Member
Premium Member
Posts: 1255
Joined: Wed Feb 02, 2005 11:54 am
Location: United States of America

Post by I_Server_Whale »

Hi,

It is really difficult to decipher what you have written. Can you please frame your question properly?

What is the objective of your job? What are you trying to implement? Please frame your questions properly.

Whale.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

It is not clear in your logic where you are trying to USE this job parameter.

What is the name of the parameter? Is it ID? Is it SrcFilter?

What I'd be looking for in such an expression, to use a comma-delimited list in a single job parameter is an IN operator (which is actually not valid).
To process a list of values, you are probably going to need to create a routine or to use dynamic array handling functions.

Another observation. Where is Cnt set? If it is a constant, then your constraint expression will only ever pass one row, and @INROWNUM will never be 1, which invalidates half of your logic.

Can you please describe the business logic - what you have to achieve - in English without reference to DataStage?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply