Changing the current directory

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
hrthomson
Participant
Posts: 25
Joined: Fri Aug 20, 2004 9:57 am
Location: Ottawa, Canada

Changing the current directory

Post by hrthomson »

We would like to implement XML source files to our project, but are running into one point of contention.

DataStage will only find the schema if the full URL or directory path is given in the xsi:schemaLocation= statement or the xsd file resides in the current project directory.

This causes environment migration issues and we would like to avoid hard coding the path if at all possible.

Has anyone run into this issue, and if so did you find a solution?

Thanks in advance

Heather
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

There's a subroutine called !MAKE.PATHNAME in DataStage BASIC that will construct a fully qualified pathname. If you leave the first argument as a zero-length string, it will return the fully-qualified pathname of its second argument. (And if you leave both empty, it returns the fully-qualified pathname of your current working directory.)

Code: Select all

Call !MAKE.PATHNAME(Arg1, Arg2, Result, Status)
Status reports whether or not Result exists, only if Arg1 and Arg2 are both non-empty. Arg2 must be a relative pathname.
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