IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

IGYPS0225-S An "EXEC SQL" statement was found


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Nagendran

New User


Joined: 24 Jan 2007
Posts: 89
Location: USA

PostPosted: Tue Aug 21, 2007 5:31 am
Reply with quote

hi,

i am executing pure DB2 pgm. I am getting below error msg.

IGYPS0225-S An "EXEC SQL" statement was found, but the "SQL" compiler option was not in effect. The statement was discarded.


when i am using sql query inside the copy book i am getting the error.if i am calling directly the compilation was successfull.

could any body help me?

regards,
Nagu
Back to top
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Tue Aug 21, 2007 6:45 am
Reply with quote

Quote:
sql query inside the copy book

This copybook is included using COPY or INCLUDE statement?
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Tue Aug 21, 2007 10:49 am
Reply with quote

The COPY statement is processed by the language compiler only, therefor the precompiler can't "see" it. Use INCLUDE instead of COPY.

O.
Back to top
View user's profile Send private message
Nagendran

New User


Joined: 24 Jan 2007
Posts: 89
Location: USA

PostPosted: Tue Aug 21, 2007 3:45 pm
Reply with quote

the solution is,while compiling DB2 program set the option

EXPAND COPY===> Y
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts How I Found a Bug in a FORTRAN Compiler All Other Mainframe Topics 4
No new posts PuTTY - "User is not a surrogate... IBM Tools 5
No new posts JCL EXEC PARM data in C Java & MQSeries 2
No new posts Newbie Stuck on "Duplicate Datas... TSO/ISPF 5
No new posts A directory in the pathname was not f... ABENDS & Debugging 0
Search our Forums:

Back to Top