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 > Error while compiling stored procedures

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-23-05, 09:31
javafolks_ssee javafolks_ssee is offline
Registered User
 
Join Date: Aug 2005
Posts: 11
Error while compiling stored procedures

Hi Folks,

I am executing a stored procedure to update some data in a table. While executing it is giving the below problem.

ECSYS.UPDATE_USER - Build started.
Create stored procedure returns -7032.

-- LOG FILE P9161521.log FOR PROCEDURE ECSYS .UPDATE_USER

-- DB2_SQLROUTINE_PREPOPTS=

-- PREP/BIND MESSAGES FOR C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp\P9161521.sqc

LINE MESSAGES FOR P9161521.sqc
------ --------------------------------------------------------------------
SQL0060W The "C" precompiler is in progress.
SQL0091W Precompilation or binding was ended with "0"
errors and "0" warnings.

-- CONTENTS OF C:\ecentre\SQLLIB\function\routine\sr_cpath.bat



-- CONTENTS OF C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp\P9161521.BAT

@echo on
set SQLROUTINE_FILENAME=P9161521
set db2path=C:\ecentre\SQLLIB

-- COMPILATION COMMAND:

nmake /f C:\ecentre\SQLLIB\function\routine\sqlproc.mak


-- CONTENTS OF C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp\P9161521.def

LIBRARY P9161521
EXPORTS _pgsjmp@8
pgsjmp=_pgsjmp@8


-- COMPILATION MESSAGES FOR C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp\P9161521.c
-- C COMPILATION ERROR CODES: 0 0 1

C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp>set SQLROUTINE_FILENAME=P9161521

C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp>set db2path=C:\ecentre\SQLLIB

C:\ecentre\SQLLIB\function\routine\sqlproc\ECSYS\E CSYS\tmp>nmake /f C:\ecentre\SQLLIB\function\routine\sqlproc.mak
'nmake' is not recognized as an internal or external command,
operable program or batch file.

-- END OF LOG FILE (SQLCODE: -7032)

ECSYS.UPDATE_USER - Build failed.
ECSYS.UPDATE_USER - Roll back completed successfully.


The entry of Compiler in SQLLIB\FUNCTION\ROUTINE is like below
COMPILER=MS
#COMPILER=IBM

Can anybody help me in resolving this. Any assistance in this regards is highly appreciated.

Thanks and best regards,
Krishna.
Reply With Quote
  #2 (permalink)  
Old 09-23-05, 10:22
jsp2999 jsp2999 is offline
Registered User
 
Join Date: Jul 2004
Posts: 76
Could you please proive input regarding your Operating System and Database version information?

Cheerrsss,
Jai
Reply With Quote
  #3 (permalink)  
Old 09-26-05, 05:14
javafolks_ssee javafolks_ssee is offline
Registered User
 
Join Date: Aug 2005
Posts: 11
Hi Jai,

The OS i am using is Windows 2003 and the DB version is "IBM DB2 Universal database version 8".

Please let me know if you need any additional information.

PS: if you don't mind can I add your yahoo id (i found with your response) so that we can discuss the things.

Thanks and best regards,
Krishna Prasad.
Reply With Quote
  #4 (permalink)  
Old 09-26-05, 07:56
nagbuchi nagbuchi is offline
Registered User
 
Join Date: Feb 2005
Location: Bangalore,India
Posts: 39
This error is because of invalid compailer path.Please set the comiler path properly as below.

db2set DB2_SQLROUTINE_COMPILER_PATH=<.... path of C /C++ compiler...>

If Visual studio(VC++) is already installed in your machine please set the path like below....

db2set DB2_SQLROUTINE_COMPILER_PATH=C:\Program Files\Microsoft Visual Studio\VC98\Bin\VCVARS32.BAT

Thanks,
Nagaraj
Reply With Quote
  #5 (permalink)  
Old 09-27-05, 09:11
javafolks_ssee javafolks_ssee is offline
Registered User
 
Join Date: Aug 2005
Posts: 11
Hi Nagraj,

Thanks for your reply. I am newbie to DB2. Please bear with me. What is meant by c/c++ compiler here. where can I find it.

Look forward to hearing from you.

Thanks and best regards,
Krishna.
Reply With Quote
  #6 (permalink)  
Old 09-27-05, 09:20
ritz ritz is offline
Registered User
 
Join Date: Jan 2005
Posts: 35
Hi Krishna,

For compiling stored procedure on DB2 UDB V8.1 you need to have a C/C++ compiler. The DB2_SQLROUTINE_COMPILER_PATH variable points to the C/C++ compiler.

If you do not have a C/C++ compiler installed on your Windows machine you can dowload cygwin and configure it.

Check this link: http://www-128.ibm.com/developerwork...306haungs.html

HTH
ritz
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