Skip to main content

Visual COBOL not connecting to Sybase

  • October 3, 2016
  • 0 replies
  • 2 views

We are migrating Workbench 4.3 COBOL to Visual COBOL 2.3 using Native Project. The programs have been in production since 2001. We are using the Sybase precompiler COBSQL/COBPRE and have the database connection information in SQL.INI file.  I successfully tested connection to Sybase with ISQL command including a table selection. However VC does not seem to identify the use of SQL.INI for connection.

I am thinking this is a configuration issue. Any thoughts would be appreciated.

The program uses the following syntax. Host variables do get set properly.

           EXEC SQL
              CONNECT :CA-SYB-LOGIN-ID
                 IDENTIFIED BY :CA-SYB-PASSWORD
                 USING :CA-SYB-SERVER-NM
           END-EXEC.
           EXEC SQL
              DECLARE @DBNAME VARCHAR(32)
              SELECT @DBNAME = RTRIM(:CA-SYB-DB-NM)
              USE @DBNAME
           END-EXEC.
                                                                                


#databaseconnection
#SQL.INI
#Sybase
#COBSQL
#COBPRE