error in routine

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
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

error in routine

Post by sudhakar_viswa »

Hi,

This is the routine code

Ans=KeyMgtGetNextValue("s1")

THe error is

Compiling: Source = 'DSU_BP/DSU.modify', Object = 'DSU_BP.O/DSU.modify'

Array 'KeyMgtGetNextValue' never dimensioned.

1 Errors detected, No Object Code Produced.

Thanks,
sudhakar
i need to know datastage
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

In your routine ("modify") you need a DEFFUN declaration to declare the catalog name and number of arguments of the KeyMgtGetNextValue routine.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

Post by sudhakar_viswa »

ray.wurlod wrote:In your routine ("modify") you need a DEFFUN declaration to declare the catalog name and number of arguments of the KeyMgtGetNextValue routine. ...

Hi ray,
I did not get exactly.
My requirement is to get next value for each time

Thanks,
sudhakar
i need to know datastage
Klaus Schaefer
Participant
Posts: 94
Joined: Wed May 08, 2002 8:44 am
Location: Germany
Contact:

Re: error in routine

Post by Klaus Schaefer »

Specify:

Deffun KeyMgtGetNextValue(A1) Calling "DSX.KeyMgtGetNextValue"

in the first line of your routine.

Klaus
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

Re: error in routine

Post by sudhakar_viswa »

Klaus Schaefer wrote:Specify:

Deffun KeyMgtGetNextValue(A1) Calling "DSX.KeyMgtGetNextValue"

in the first line of your routine.

Klaus
Hi Klaus,

Thanks.Now it is not showing any error.But i have specified


Deffun KeyMgtGetNextValue(A1) Calling "DSX.KeyMgtGetNextValue"
Ans=KeyMgtGetNextValue("s1")

while testing it is showing <<ERROR>> in result.

it is not giving any value to Ans.

Thanks,
sudhakar
i need to know datastage
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Why don't you go to the manager and do a test run run directly in KeyMgtGetNextValue using your test value of "s1". Does that work or show any errors?
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

Post by sudhakar_viswa »

ArndW wrote:Why don't you go to the manager and do a test run run directly in KeyMgtGetNextValue using your test value of "s1". Does that work or show any errors? ...
Hi ArndW,

I need to take the value from routine that is my requirement.

Thanks,
sudhakar
i need to know datastage
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Double click on the cell that shows <<ERROR>> in the Test grid and report what is displayed there.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

Post by sudhakar_viswa »

ray.wurlod wrote:Double click on the cell that shows <<ERROR>> in the Test grid and report what is displayed there. ...
Hi Ray,

It is showing like the following..

TEST #1
*******

Arg1 = 1

Test failed.

Program "DSU.modify": Line 5, Unable to open the operating system file "DSU_BP.O/DSX.KeyMgtGetNextValue".
[ENOENT] No such file or directory
Program "DSU.modify": Line 5, Unable to load file "DSX.KeyMgtGetNextValue".
Program "DSU.modify": Line 5, Unable to load subroutine.


Thanks,
sudhakar
i need to know datastage
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Change you declaration line to read

Code: Select all

Deffun KeyMgtGetNextValue(A1) Calling "DSX.KEYMGTGETNEXTVALUE" 
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

Post by sudhakar_viswa »

ArndW wrote:Change you declaration line to read

Code: Select all

Deffun KeyMgtGetNextValue(A1) Calling "DSX.KEYMGTGETNEXTVALUE" 
...
Hi ArndW,

Thanks.It is working.I need to rename the file after it is processed like following.

before after
fileaA fileA_1_currentdatetime
fileaA fileA_2_currentdatetime
fileaA fileA_3_currentdatetime

daily i have to run the same file.

Thanks,
sudhakar
i need to know datastage
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Search the (server) forum. This question has been answered five times to my certain knowledge.

Etiquette Notes
1. Start a new thread for a new topic.
2. Search before posting, or pay someone to do it.
3. Post in the correct forum.
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