If I place the cursor on W900-CUR and press Shift F12 Visual COBOL won't find any references. However, if I search for W900-CUR I will clearly see that the variable is used throughout the programme. Is this by design?
EXEC SQL BEGIN DECLARE SECTION END-EXEC.
01 W900-CUR SQL-CURSOR.
EXEC SQL END DECLARE SECTION END-EXEC.
This is working fine for me in Visual COBOL 5.0 PU7 for VS 2019.
If I place the cursor on W900-CUR and press Shift F12 Visual COBOL won't find any references. However, if I search for W900-CUR I will clearly see that the variable is used throughout the programme. Is this by design?
EXEC SQL BEGIN DECLARE SECTION END-EXEC.
01 W900-CUR SQL-CURSOR.
EXEC SQL END DECLARE SECTION END-EXEC.
Is this the OpenESQL preprocessor you are using or another preprocessor such as procob/cobsql or DB2?
I tested this here with OpenESQL and the find all references works fine with host variables defined in the BEGIN DECLARE block.
Does this not work for all variables or just this particular one?
I tested this with Visual COBOL for Visual Studio 2019 V5.0 PU7.
Is this the OpenESQL preprocessor you are using or another preprocessor such as procob/cobsql or DB2?
I tested this here with OpenESQL and the find all references works fine with host variables defined in the BEGIN DECLARE block.
Does this not work for all variables or just this particular one?
I tested this with Visual COBOL for Visual Studio 2019 V5.0 PU7.
No, I'm using the Pro*Cobol preprocessor.
If I do it the other way round, i.e. place the cursor on one of the places where the variable is used, and press F12 (go to definition) then I come to the line where the variable is declared. In other words, that works.
No, I'm using the Pro*Cobol preprocessor.
If I do it the other way round, i.e. place the cursor on one of the places where the variable is used, and press F12 (go to definition) then I come to the line where the variable is declared. In other words, that works.
The Find References on Host Variables when using Procob/CobSQL does not work. If you hover over the data item in working-storage you will see that the tooltip will display that No References were found if it is only referenced within an EXEC SQL block.
This does work for OpenESQL as this is a Micro Focus preprocessor whereas Procob is an Oracle product.