Difference between Routine and Transform

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

Difference between Routine and Transform

Post by sudhakar_viswa »

Hi,

I know that Routine will return only one vale.Is it right or wrong,reply me.And what is the difference between Routine and Transform.


Thanks,
sudhakar
i need to know datastage
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

Search

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

Post by sudhakar_viswa »

Hi,

I have searched so many times,but the thing is idid not get correct information.

Thanks,
sudhakar
i need to know datastage
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

If you could click on the 'Search' in the previous post you can get one :wink:

-Kumar
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Although the topic has been covered several times, the answer isn't that complicated. A DataStage "Routine" is actually a function in most programming languages, it takes 0 through 254 arguments and returns a single value value. A DataStage transform is effectively also a function in that the whole transform gets evaluated to a single value at runtime,but the difference is that when you use a transform in a DataStage job the contents of the transform are inserted into the job at compile time; Routines are called by reference.

One difference is that when you change a transform you will need to recompile all jobs that use it and you do not need to do that with Routines. Since transforms don't have the overhead of calling a catalogued routine they execute faster than routines. Transforms are limited to single-line constructs while Routines can be very long and complex programs.
sudhakar_viswa
Participant
Posts: 85
Joined: Fri Nov 18, 2005 5:35 am

Post by sudhakar_viswa »

Hi,

Thanks arnd.

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 »

I have to say that the official training is wrong on point (1) and although strictly speaking point (2) isn't incorrect it doesn't explain the major difference in how the code is executed at runtime.

The initial purpose might have been to use specific data type and elements in transforms, but it is not controlled and the purpose of a transform is not to transform from one data type to another.

The technical term for what transforms do is "inline expansion".
srividya
Participant
Posts: 62
Joined: Thu Aug 25, 2005 2:31 am
Location: Ashburn,VA

Post by srividya »

Thanks Arnd for the info
Post Reply