IGYDS0225-S An "EXEC SQL" statement was found



Support for OS/VS COBOL, VS COBOL II, COBOL for OS/390 & VM and Enterprise COBOL for z/OS

IGYDS0225-S An "EXEC SQL" statement was found

Postby CobDummy » Thu Jul 14, 2016 2:19 pm

Hi,

Could someone please guide.

I am getting following error
"IGYDS0225-S An "EXEC SQL" statement was found, but the "SQL" compiler option was not in effect. The statement was discarded."


ID DIVISION.            
PROGRAM-ID. CALLSP.    
                       
DATA DIVISION.          
WORKING-STORAGE SECTION.
    EXEC SQL            
         INCLUDE SQLCA  
    END-EXEC.          
                       
PROCEDURE DIVISION.    
PROGRAM-BEGIN.          
    EXEC SQL            
         CALL SQLPROC1  
    END-EXEC.          
                       
PROGRAM-DONE.          
    STOP RUN.          
CobDummy
 
Posts: 12
Joined: Wed Mar 30, 2016 2:53 pm
Has thanked: 0 time
Been thanked: 0 time

Re: IGYDS0225-S An "EXEC SQL" statement was found

 

Re: IGYDS0225-S An "EXEC SQL" statement was found

Postby Robert Sample » Thu Jul 14, 2016 3:24 pm

In order to compile SQL statements, the compiler option SQL MUST be specified. The error message is clear - what part of it do you have trouble understanding?
Robert Sample
Global moderator
 
Posts: 3354
Joined: Sat Dec 19, 2009 8:32 pm
Location: East Dubuque, Illinois
Has thanked: 1 time
Been thanked: 219 times

Re: IGYDS0225-S An "EXEC SQL" statement was found

Postby CobDummy » Thu Jul 14, 2016 4:05 pm

Hi.. actually I am new in mainframes.. not sure what needs to be done can you please help
CobDummy
 
Posts: 12
Joined: Wed Mar 30, 2016 2:53 pm
Has thanked: 0 time
Been thanked: 0 time

Re: IGYDS0225-S An "EXEC SQL" statement was found

Postby Robert Sample » Thu Jul 14, 2016 4:59 pm

Talk to your site support group and get their help. There are so many ways to compile a COBOL program -- through a batch job stream or through a TSO command or through a Unix command or through an ISPF option and the source can come from a PDS, through CA-LIBRARIAN, through Endevor, through Panvalet, etc -- that every site has their own way to compile programs. You need to find out -- from co-workers, your team leader, your manager, or your site support group -- how to compile a COBOL program with SQL statements. Since this is site-specific, there's not really anything anyone on this - or any other - forum can do to help you since we don't work at your site and have no idea how things are set up there. But there is a way at your site to specify options to the COBOL compiler, and you need to find that way and use it to add SQL to the options for your compile.
Robert Sample
Global moderator
 
Posts: 3354
Joined: Sat Dec 19, 2009 8:32 pm
Location: East Dubuque, Illinois
Has thanked: 1 time
Been thanked: 219 times

Re: IGYDS0225-S An "EXEC SQL" statement was found

Postby CobDummy » Thu Jul 14, 2016 6:52 pm

Thank you Robert. I will try to find out.
CobDummy
 
Posts: 12
Joined: Wed Mar 30, 2016 2:53 pm
Has thanked: 0 time
Been thanked: 0 time


Return to IBM Cobol

 


  • Related topics
    Replies
    Views
    Last post