how to write 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
sekharg_dw
Participant
Posts: 19
Joined: Mon Jul 18, 2005 5:37 am

how to write routine

Post by sekharg_dw »

How to write routine and please explain with simple routine :P
sekhar g
mumbai
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Same answer as when you asked this over in the PX forum. They are written in the Manager and that's your best resource for examples. All of the routines in there have source code, just double-click on them to see it.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

How To Write Routine (server routine)

Start with a specification of what you want to achieve. The specification is written in normal language, for example English.

Formalize the input arguments needed; seek opportunities to make a more flexible reusable component.

Determine whether your need is a before/after subroutine or a transform function.

Have the specification reviewed (for example peer review). If it's a business requirement, have the business sign off that the specification is correct.

Design test data that ensure that invalid values, boundary conditions, and so on are handled appropriately.

Translate into DataStage BASIC, save, compile and test. Fix any syntax errors that prevent compilation. If any test result does not yield what was expected, investigate and correct the situation.
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