Page 1 of 1

How can I load this ""DSU_BP.O/DSU.ExecuteSQL"

Posted: Tue Dec 05, 2006 6:38 am
by bollinenik
Hi,

Following error I am getting while testing that routine pls help me.

TEST #1
*******

Arg1 = C
Arg2 = 200612
Arg3 = Process_Claims_J060_Seq
Arg4 = gmodc
Arg5 = gwmoraods
Arg6 = gwmoraods

Test failed.

Program "DSU.UpdProcessStatus": Line 28, Unable to open the operating system file "DSU_BP.O/DSU.ExecuteSQL".
[ENOENT] No such file or directory
Program "DSU.UpdProcessStatus": Line 28, Unable to load file "DSU.ExecuteSQL".
Program "DSU.UpdProcessStatus": Line 28, Unable to load subroutine.

How Can I load this file into DS

How can I solve this.

Thanks In advance.

Posted: Tue Dec 05, 2006 7:21 am
by DSguru2B
Need to look at your routine. From the looks of it, you did not let the compiler know that you will be using other user-defined routines within yours. You need a deffun prototype at the top of your routine.

Posted: Tue Dec 05, 2006 7:46 am
by ArndW
You do not have the routine "ExecuteSQL" declared or compiled.

Posted: Tue Dec 05, 2006 7:49 am
by bollinenik
I am using some other routine only, But i compiled successfully and where I can change that prototype fo that routine.
pls see below code of my routine
"
$Include DSINCLUDE JOBCONTROL.H

Deffun ExecuteSQL(SQLSTMT,DBDSN, DBUSER, DBPASS) Calling "DSU.ExecuteSQL"

* /home/dsadm/Telstra/parameters.lst
I.JOBSTAT = PJOBSTAT
I.ODBC = DBDSN
I.User = DBUSER
I.Password = DBPASS
I.PROCS_EXCTN_ID = PROCS_EXCTN_ID
I.PROCS_NM = PROCS_NM

L.CallingJobName = Trim(DSGetJobInfo(DSJ.ME, DSJ.JOBNAME))

********************************************************************************
* Retrieve Parameter
********************************************************************************
L.SQL = "SELECT PROCS_NM FROM PROCS WHERE PROCS_NM ='":I.PROCS_NM:"'"
L.PROCS_NM = ExecuteSQL(L.SQL,I.ODBC,I.User,I.Password);

If L.PROCS_NM <> "" Then

********************************************************************************
* Update PROCESS_LOG
********************************************************************************
L.SQL = "SELECT SUM((SB_PROCS_END_DT- SB_PROCS_START_DT)*24*3600) FROM sb_procs_log WHERE PROCS_NM='":I.PROCS_NM:"' AND PROCS_EXCTN_ID=":I.PROCS_EXCTN_ID

L.ELAPSED_TM = ExecuteSQL(L.SQL,I.ODBC,I.User,I.Password);

L.SQL = "UPDATE PROCS_LOG SET STAT_CD='":I.JOBSTAT:"', PROCS_END_DT =SYSDATE WHERE PROCS_NM='":I.PROCS_NM:"' AND PROCS_EXCTN_ID=":I.PROCS_EXCTN_ID

L.ExecuteSQL = ExecuteSQL(L.SQL,I.ODBC,I.User,I.Password);

End

If L.ExecuteSQL <> "" Then
Call DSLogFatal("Cannot Update PROCS_LOG ":L.PROCS_NM:"AND PROCS_EXCTN_ID=":I.PROCS_EXCTN_ID,L.CallingJobName)
End

Ans = L.ExecuteSQL"

This is the code but there ia m not able to find that "excute.sql" file how can i do this

Posted: Tue Dec 05, 2006 7:51 am
by meena
Hi Koti,
The error shows that there is no such file or directoty. Check whether you have the right path and right file name. And post your routine.

Posted: Tue Dec 05, 2006 7:56 am
by bollinenik
And I have a file called "D_DSU_BP.O" there is no folder under how i can add "DS.EXCUTE.SQL" AND HOW CAN I DO THIS PLS LET ME KNOW

Posted: Tue Dec 05, 2006 7:59 am
by bollinenik
Hi Meena,

I posted my total routine code pls gothrough that and if you and find anything pls let me know

Thanks in Advance

Posted: Tue Dec 05, 2006 8:01 am
by ArndW
There is folder in your project directory called DSU_BP.O which contains the compiled object code. The object code for the user defined ExecuteSQL routine is not in there. If you have the source to this in your project then compile it.

Posted: Tue Dec 05, 2006 8:14 am
by bollinenik
Hi Andrew,

Yes I have that folder in side that there is no routine for "excute.sql",I have routines inside that for "excute.SH,excute.TCL" So,
For me there is no routine for "EXCUTE.SQL" Can any one tell me how can i Proceed and how can i get that routine and how to Solve this

Thanks In Advance.

Posted: Tue Dec 05, 2006 8:24 am
by chulett
As noted several times now, all you should have to do is compile the 'ExecuteSQL' routine. Please make sure you do that before we go around in any more circles. :?

Posted: Tue Dec 05, 2006 8:25 am
by ArndW
ExecuteSQL is not a builtin DataStage routine. Using your Manager, look in your Routines to see if you have the source, if so then compile it. If not, then try to find out where you got this routine from and load it.