TypeCobol icon indicating copy to clipboard operation
TypeCobol copied to clipboard

SQL tests : surround each instruction by EXEC SQL

Open smedilol opened this issue 2 years ago • 0 comments

What is the current problem With our Cobol compiler, when there is an error in SQL, only the first error is reported in a block of EXEC SQL.

Cobol code to illustrate.

           EXEC SQL
              GET DIAGNOSTICS  :var01 = ALL CONDITION :var02
      *Errors on this second instruction are not reported
              GET DIAGNOSTICS  :var01 = ALL STATEMENT
           END-EXEC.

Describe the solution you'd like Therefore in order to get all SQL problems at once, we need to surround each instruction by EXEC SQL/END-EXEC.

Cobol code to illustrate.

           EXEC SQL
              GET DIAGNOSTICS  :var01 = ALL CONDITION :var02
           END-EXEC.

           EXEC SQL
              GET DIAGNOSTICS  :var01 = ALL STATEMENT
           END-EXEC.

Technical Update only existing SQL tests. Don't create new tests.

How to test automatically Only lines of error must change. No new errors.

smedilol avatar Aug 08 '22 09:08 smedilol