If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Stored procedure compile errror

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-23-04, 07:20
quigleyd quigleyd is offline
Registered User
 
Join Date: Nov 2002
Location: Delaware
Posts: 186
Stored procedure compile errror

I am trying to compile a store procedure in DB2 V8, Fixpak 5, on AIX 5.2. Any ideals would be appreciated. I can compile other C programs with no problem, just not a stored procedured. I have added the I am getting the following:
I added the following to my profile
DB2_SQLROUTINE_COMPILE_COMMAND=xlc -I$HOME/sqllib/include SQLROUTINE_FILENAME.c -bEQLROUTINE_FILENAME.exp -e pgsjmp -o SQLROUTINE_FILENAME -L$HOME/sqllib/lib -ldb2


-- COMPILATION MESSAGES FOR /db2/EOP/sqllib/function/routine/sqlproc/PEDWETL/ETL/tmp/P3450980.c
sh: xlC_r: not found.

-- END OF LOG FILE (SQLCODE: -7032)
ETL.SP_GET_THRESH - Build failed.
ETL.SP_GET_THRESH - Roll back completed successfully.

The body of the stored proc is as follows:

CREATE PROCEDURE INFORMAT.SP_GET_THRESH(OUT CNT1 INTEGER)
MODIFIES SQL DATA
NOT DETERMINISTIC
LANGUAGE SQL
BEGIN
select count(*) into CNT1 from etl_process_control where WF_STAT='R';
END
__________________
David Quigley
Reply With Quote
  #2 (permalink)  
Old 09-23-04, 15:43
dbamota dbamota is offline
Registered User
 
Join Date: Sep 2003
Posts: 237
our profile reads(relevant lines only)
db2inst1>db2set -all
[i] DB2_SQLROUTINE_COMPILER_PATH=/home/db2inst1/sqllib/function/routine/sr_cpath
[i] DB2_SQLROUTINE_COMPILE_COMMAND=/usr/vac/bin/xlc -H512 -T512 -g -I/crmdbhome/01/db2inst1/sqllib/include SQLROUTINE_FILENAME.c -bEQLROUTINE_FILENAME.exp -e
SQLROUTINE_ENTRY -o SQLROUTINE_FILENAME -L/crmdbhome/01/db2inst1/sqllib/lib -lc-ldb2

vaguely remember checking entries in a file in compiler path; xlc in our case is in /usr/vac/bin/ ;
__________________
mota
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On