Symptom
We have cobol program that calls sql stored procedure provided by vendor that works with Sybase 12.5 32 bit and Micro Focus 32 bit. When we compile the same program with Sybase 15.7 64bit and Micro Focus Cobol 64 bit, the stored procedure is invoked and it updates the value in the database but does not return that value to working storage for display.
One thing I notice is the $SYBASE/$SYBASE_OCS/include/sybhesql64.cbl is different then $SYBASE/$SYBASE_OCS/include/sybhesql.cbl is different (as expected).
However when I make changes in $SYBASE/$SYBASE_OCS/include/sybhesql64.cbl as highlighted in red below, it works (changes were only made to investigate the issue).
Following is part of listing of sybhesql64.cbl (rel157) and sybhesql.cbl (rel1205) in its original format:
$SYBASE/$SYBASE_OCS/include/sybhesql64.cbl $SYBASE/$SYBASE_OCS/include/sybhesql.cbl
01 SQL--DFMTDFMT-NAME. 01 SQL--DFMTDFMT-NAME.
05 SQL--NM PIC X(256). 05 SQL--NM PIC X(132).
05 SQL--NMLEN PIC S9(9) comp value is 0. 05 SQL--NMLEN PIC S9(9) comp value is 0.
05 SQL--DATATYPE PIC S9(9) comp value is 100. 05 SQL--DATATYPE PIC S9(9) comp value is 100.
05 SQL--FORMAT PIC S9(9) comp value is 1. 05 SQL--FORMAT PIC S9(9) comp value is 1.
05 SQL--MAXLENGTH PIC S9(9) comp value is 0. 05 SQL--MAXLENGTH PIC S9(9) comp value is 0.
05 SQL--SCALE PIC S9(9) comp value is 0. 05 SQL--SCALE PIC S9(9) comp value is 0.
05 SQL--PRECISION PIC S9(9) comp value is 18. 05 SQL--PRECISION PIC S9(9) comp value is 18
05 SQL--STTUS PIC S9(9) comp value is 0. 05 SQL--STTUS PIC S9(9) comp value is 0.
05 SQL--COUNT PIC S9(9) comp value is 1. 05 SQL--COUNT PIC S9(9) comp value is 1
05 SQL--USERTYPE PIC S9(9) comp value is 0. 05 SQL--USERTYPE PIC S9(9) comp value is 0.
05 SQL--LOCALE PIC S9(18) comp value is 0. 05 SQL--LOCALE PIC S9(9) comp value is 0
After changing the $SYBASE/$SYBASE_OCS/include/sybhesql64.cbl:
01 SQL--DFMTDFMT-NAME. 01 SQL--DFMTDFMT-NAME.
05 SQL--NM PIC X(132). 05 SQL--NM PIC X(132).
05 SQL--NMLEN PIC S9(9) comp value is 0. 05 SQL--NMLEN PIC S9(9) comp value is 0.
05 SQL--DATATYPE PIC S9(9) comp value is 100. 05 SQL--DATATYPE PIC S9(9) comp value is 100.
05 SQL--FORMAT PIC S9(9) comp value is 1. 05 SQL--FORMAT PIC S9(9) comp value is 1.
05 SQL--MAXLENGTH PIC S9(9) comp value is 0. 05 SQL--MAXLENGTH PIC S9(9) comp value is 0.
05 SQL--SCALE PIC S9(9) comp value is 0. 05 SQL--SCALE PIC S9(9) comp value is 0.
05 SQL--PRECISION PIC S9(9) comp value is 18. 05 SQL--PRECISION PIC S9(9) comp value is 18
05 SQL--STTUS PIC S9(9) comp value is 0. 05 SQL--STTUS PIC S9(9) comp value is 0.
05 SQL--COUNT PIC S9(9) comp value is 1. 05 SQL--COUNT PIC S9(9) comp value is 1
05 SQL--USERTYPE PIC S9(9) comp value is 0. 05 SQL--USERTYPE PIC S9(9) comp value is 0.
05 SQL--LOCALE PIC S9(9) comp value is 0. 05 SQL--LOCALE PIC S9(18) comp value is 0
Read more...
Environment
SAP SDK 15.7 64bit and Micro Focus Cobol 64 bit
Product
Keywords
KBA , BC-SYB-SDK , SDK , Bug Filed
About this page
This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.