Page 1 of 1

Retrieve inforformation in Dataset Stage

Posted: Tue Nov 13, 2007 4:47 am
by bart12872
Hello,

I have a project with, let's say 1000 jobs. Among this job, there are dataset stage (input or output).

I Want to create a file with three colums :
1 - Job Name
2 - Dataset(s) input (file name + path)
3 - Dataset(s) output (file name + path)

I retrieve the list of jobs, i can determine the stage which are dataset, i can determine if the dataset is an input or an ouput dataset,
but It missed me the name of the dataset. I thougth i could have the name with DSJ.STAGEDESC or DSJ.VARLIST (DsGetStageInfo)
but those option return DSJE.BADSTAGE. (if I use for exemple the option DSJ.STAGENAME i don't have the return DSJE.BADSTAGE)

Is it possible to request directly the repository, as I do to retrieve the job's list ?

Anyone have an idea to do that ?

bart.

Posted: Tue Nov 13, 2007 4:23 pm
by ray.wurlod
DSGetJobInfo(hJob,DSJ.STAGELIST) will return a list of active stages. You may prefer DSJ.JOBFULLSTAGELIST to get all stage names. From that you will need to use DSGetStageInfo() to retrieve a list of link names, and from each link DSGetLinkInfo() can return information about the link. However, there is no DSGetLinkInfo() call that returns the name of the file/table.

To query the Repository directly you would need to find the correct record in DS_JOBOBJECTS. You can certainly filter on OLETYPE, but the Data Set control file pathname would be in an undocumented column. Right now I don't have access to Enterprise Edition, but perhaps someone could chirp in with the field number.