DSCheckRoutine

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
thurmy34
Premium Member
Premium Member
Posts: 198
Joined: Fri Mar 31, 2006 8:27 am
Location: Paris

DSCheckRoutine

Post by thurmy34 »

Hi
Apparently the DSCheckRoutine does not work for the before/after routine.

Here my code

Code: Select all

if (NOT(DSCheckRoutine("DSU.FWKCommunDSLogJournalv2"))) Then
         Call DSLogFatal(" La routine DSU.FWKCommunDSLogJournalv2 est absente du projet",'')
      end else
         deffun DSLogJournal (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) Calling "DSU.FWKCommunDSLogJournalv2"
      end
When the routine is a transform one it's ok , when is a before/after the chek failed.
Hope This Helps
Regards
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

No clue but it really shouldn't be called that way. Try changing your call to reflect this syntax and see if it changes the behaviour you are seeing:

Code: Select all

Found = DSCheckRoutine(RoutineName)
-craig

"You can never have too many knives" -- Logan Nine Fingers
thurmy34
Premium Member
Premium Member
Posts: 198
Joined: Fri Mar 31, 2006 8:27 am
Location: Paris

Post by thurmy34 »

Hi
I changed my code to this

Code: Select all

Found=DSCheckRoutine("DSU.FERMATBale2RExecDosRename")
      If(NOT(Found)) Then
         Call DSLogFatal(" La routine DSU.FERMATBale2RExecDosRename est absente du projet",'')
      end
I hope it was what you want me to do because i'm no longer be a premium member.
The behaviour is the same.
Hope This Helps
Regards
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Then you might prefer the !EXIST routine, which you will find documented in the DataStage BASIC manual.

Another possibility is that DSCheckRoutine() is OK, but your routine has not successfully been compiled yet.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
thurmy34
Premium Member
Premium Member
Posts: 198
Joined: Fri Mar 31, 2006 8:27 am
Location: Paris

Post by thurmy34 »

Hi All
I'm using TRANS now and it works perfectly.

Ray : i didn't fing the !EXIST routine ind DataStage Basic Guide or in the help.

Thank you again
Hope This Helps
Regards
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Anyway, TRANS() from VOC is OK within the DataStage context, unless you happen to be using globally cataloged routines, in which case the TRANS() needs to be applied against GLOBAL.CATDIR.

And that's where !EXIST is cataloged. You can use the MAP command to verify that it's there. You may need to have recourse to the UniVerse BASIC manual for documentation.
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