Skip to Content

Creating ASEODBC Connection from SAP Sybase IQ to SAP ASE

Steps listed below can be used to setup remote connection from SAP Sybase IQ and SAP Sybase Adaptive Server Enterprise. First you will need to install  OCS 157 64 bit  on IQ HOST machine for using ASE odbc driver


1. setup Environment variables.

cd to $SYBASE/IQ-15_4 and edit IQ-15_4.csh and add:

   setenv LIBPATH "${LIBPATH}:/usr/sybase/rel157/DataAccess64/ODBC/lib"

   setenv PATH "${PATH}:/usr/sybase/rel157/DataAccess64/ODBC/lib"

setenv ODBCINI /usr/sybase/rel154_iq_esd3/odbc.ini

  setenv ODBCHOME /usr/sybase/rel154_iq_esd3/

   2. source IQ-15_4.csh

   3. Add SAP Adaptive Server Enterprise and SAP Sybase IQ Server entries in interfaces

   % cat $SYBASE/interfaces

        aixase157

          master tcp ether ASEHOST 8412

          query tcp ether ASEHOST 8412

   iq154

          master tcp ether IQHOST 9522

          query tcp ether IQHOST 9522

   4. % cat $SYBASE/odbc.ini

   [aixase157]

  Description = Sybase ODBC Data Source

  UserID = sa

  Password =

  Driver = /usr/sybase/rel157/DataAccess64/ODBC/lib/libsybdrvodb.so

  Server = ASEHOST

  Port =  8412

  Database = pubs2

  UseCursor = 1

   [iq154]

  DRIVER=/usr/sybase/rel154_iq_esd3/IQ-15_4/lib64/libdbodbc12.so

  EngineName=iq154

  CommLinks=tcpip(host=IQHOST;port=9522)

  Userid=DBA

  Password=sql

  AutoStop=no

  DatabaseName=iqdemo

5. stop and restart IQ server

  6. Create Server and externlogin

     % dbisql -c 'dsn=iq154' -nogui

   (DBA)> select @@version

        @@version

  --------------------------------------------------------------------------------

Sybase IQ/15.4.0.3027/130814/P/ESD 3.6/Enterprise Linux64 - x86_64 - 2.6.18-194.el5/64bit/2013-08-14 03:34:24

(1 rows)

   Execution time: 0.014 seconds

  (DBA)> create server aixase157 class 'ASEODBC' usin

'Description=Sybase ODBC Data Source;Driver=/indigo61/sbagai/rel157/DataAccess64/ODBC/lib/libsybdrvodb.so;

UserID=sa,Password=;Server=indigo6;Port=8412;Database=pubs2;UseCursor=1'
;

  Execution time: 0.036 seconds

(DBA)> create externlogin DBA to aixase157
remote login 'sa' ;

Execution time: 0.032 seconds

(DBA)> forward to aixase157

0 row(s) affected

Execution time: 0.01 seconds

(DBA)> select @@version

expr_1

  --------------------------------------------------------------------------------

---------------

Adaptive Server Enterprise/15.7.0/EBF 19803SMP ESD#01 /P/RS6000/AIX 6.1/aseasap

/2918/64-bit/FBO/Wed Feb  8 06:09:12 2012

(1 rows)

Execution time: 0.85 seconds

(DBA)>

Tags: