Page 1 of 1

How to get Job log before compilation ?

Posted: Wed Feb 22, 2006 12:04 am
by Nageshsunkoji
Hi Folks,

I have a requirement to get the Job logs before compilation. For Ex : Some unknown person changed something in my code and he simply saved that job and he didn't comile that Job. In my next run when i compile the same job i am getting the modifications which are not done by me.So, my question is how to get the Job log before compilation with time and user id(optional) when it was last modified. So, anybody have faced this type of problems in your project ? what will be the solution for this ? any routines or scripts are there to get this info ?
Your inputs are most appreciatable.

Regards
Nagesh.

Posted: Wed Feb 22, 2006 12:25 am
by ray.wurlod
The job log is not removed by compilation. Job log events are purged only if you have automatic purge enabled, and then only on successful completion of a normal run. So you ought to be able to get entries from the log unless the above conditions obtain, in which case they are lost forever.

However, there is a table called DS_AUDIT in the Repository that records all edits (well, most of them anyway) including not just date/time modified but also the user ID who effected the modification. In the Administrator client command window, or at a TCL prompt on the server, query this table.

Code: Select all

SELECT * FROM DS_AUDIT WHERE CLASS = '2' AND INSTANCE = 'jobname';

Posted: Wed Feb 22, 2006 2:19 am
by Nageshsunkoji
Hi Ray,

Thanks for your reply. You gave me good information regarding DS_AUDIT table. But, as of now i don't have Administrtaor Privileges to perform this query. Can you suggest me how to get the same information as developer point of view. Presently i have access of DS designer and Director. My operating system is a Unix one.

Thanks & Regards
Nagesh.

Posted: Wed Feb 22, 2006 2:24 am
by ArndW
You can execute this query from the TCL environment from UNIX as well. You need to make sure your shell has executed the ".dsenv" script to set up the environment variables, then attach to the project directory and execute "$DSHOME/bin/dssh" to enter TCL; then you can perform the SELECT as Ray has outlined. To exit the TCL environment back into UNIX you need to enter the command "QUIT".

Posted: Wed Feb 22, 2006 3:03 am
by ray.wurlod
You do not need Administrator privilege to run this command.

Posted: Wed Feb 22, 2006 3:43 am
by Nageshsunkoji
Hi Ray & Arnd,

I executed the query in TCL but i am getting following message :

sac@lpar5m:/dstage/dsadm/Ascential/DataStage/DSEngine:$ . ./dsenv
sac@lpar5m:/dstage/dsadm/Ascential/DataStage/DSEngine:$ bin/dssh
DataStage Command Language 7.5
Copyright (c) 1997 - 2004 Ascential Software Corporation. All Rights Reserved
DSEngine logged on: Wednesday, February 22, 2006 01:32

>SELECT * FROM DS_AUDIT WHERE CLASS='2' AND INSTANCE='Dimension'
Retrieve: syntax error. Unexpected sentence without filename. Token was "".
Scanned command was SELECT * FROM 'DS_AUDIT' WHERE 'CLASS' = '2' AND 'INSTANCE' = 'Dimension'

Please correct me i am doing any wrong things.

Regards
Nagesh.

Posted: Wed Feb 22, 2006 4:06 am
by ArndW
Append a semicolon (;) to your command. If you don't do this, then the engine will attempt to parse the command as a DataStage "SELECT" command, which has a different syntax.

Posted: Wed Feb 22, 2006 12:13 pm
by kumar_s
>LOGTO <Project_Name>
This should solve your issue.
This allows to logto you project account. DS_AUDIT is an project specific file. Pls note that project names are case sensitive.

Posted: Wed Feb 22, 2006 10:30 pm
by Nageshsunkoji
Hi All,

Thanks a ton for your inputs.
Now i am able to see the DS_AUDIT table in the TCL server.

Is it possibel to get this details in the Text file by using Shell script ?

If so suggest me how to write the shell script to get this details ?

Thanks & Regards
Nagesh.

Posted: Thu Feb 23, 2006 1:57 am
by ArndW
If you enter the command "COMO ON {filename}" it will begin echoing all terminal I/O to a UNIX file called "{filename}" in a subdirectory called &COMO& in your project directory. You need to execute the command "COMO OFF" to stop recording data to the file.

Posted: Thu Feb 23, 2006 2:20 am
by ray.wurlod
Read this post and adapt the advice given there.

Posted: Thu Feb 23, 2006 10:02 pm
by Nageshsunkoji
Hi Ray & Arnd,

Great Inputs .

Thanks for your Inputs.

Regards
Nagesh.

Posted: Fri Feb 24, 2006 8:29 am
by ThilSe
Hi,

Is there any help file or Are these table informations documented somewhere?

How can I get more information about these tables and the uses?

Thanks/Regards
Senthil

Posted: Fri Feb 24, 2006 8:35 am
by ArndW
Senthil,

the DS_... and RT_... hashed files or tables are not documented by IBM/Ascential. Their contents and use change between versions so IBM/Ascential will never officially document them, since that will remove their flexibility of changing them for ever.