Closed FALLAI-Denis closed 9 months ago
Can you provide me with a sample program where you are seeing this issue?
Hi,
Sample code:
IDENTIFICATION DIVISION.
PROGRAM-ID. TSTSQLCA.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 HOWMUCH PIC S9(9) COMP-5.
>>define isDB2 as b'1'
>>if isDB2
exec sql include sqlca end-exec.
>>end-if
PROCEDURE DIVISION.
MAIN.
exec sql
select count(*) into :HOWMUCH
from SYSIBM.SYSDUMM1
end-exec
if SQLCODE not = 0 and SQLCODE not = +100
display "Oups !"
end-if
.
BYE.
goback.
Thanks, I see the issue and will see what can be done to fix it.
Fixed in v3.4.0.
Development environment used
Problem Description
Almost all of the source code analysis issues related to the use of conditional compilation have been resolved in the latest versions of ZOE, and once again I thank you for your efforts.
However, a new case has just been identified:
Observed behavior
With SQLCA declaration under conditional compilation (even if the condition is true):
With SQLCA declaration not under conditional compilation:
This suggests that the COBOL Language Server processes the EXEC SQL statements before having processed the conditional compilation.