Forum Stats

  • 3,782,434 Users
  • 2,254,645 Discussions


Connection name questions & problems

411198 Member Posts: 154
edited Sep 28, 2008 2:30PM in Heterogeneous Connectivity

Is there a length limitation on HSODBC connection names? Or a uniqueness requirement?

I had 2 entries named "b0mausqldev1" and "b0mausqldev1_ald" and HSODBC always connected to "b0mausqldev1". The initb0mausqldev1_ald1.ora, listener.ora, tnsnames.ora and ODBC.INI were all correct. The solution was to change the name from "b0mausqldev1_ald" to "sqldev1_ald".

The ISQL utility (part of UNIXODBC/FREETDS) worked with all of the name variations so that leads me to believe it is an HSODBC / Oracle networking issue.

TNSPING reported a good connection but it is hard to tell which connection it was using.

I am using FREETDS and UNIXODBC, Oracle on AIX; connecting to SQL Server 2000.

Also found out that Oracle does not like "-" in database link names. ;)


Dave Venus


  • Kgronau-Oracle
    Kgronau-Oracle Posts: 2,550 Employee
    The Oracle 9i Database Administrator's Guide lists the SID restrictions:
    Each Oracle instance must have a SID. A SID us a unique name for an Oracle database that can be up to 64 alphanumeric characters in length.

    But I've also seen problems in some versions with more then 12 characters as the listener didn't handle it correctly.
    Commonly to diagnose this kind of problems a listener trace is more helpfull then the tnsping utility as TNSPING is NOT looking for any SID. It is just pinging the listener process and check if there is something alive on this machine and listening on this port.
    So even it replies a success there is no guarantee the SID exists. You should always check the listener status as well.

    If you want to check out which SID is used, you should enable LISTENER tracing:
    lsnrctl <ENTER>
    set TRC_LEVEL support
    now open SQL*Plus and try the DB link
    afterwards disable tracing again:
    lsnrctl <ENTER>
    set TRC_LEVEL off

    Now examine the trace file.

    As a final word:
    Keep in mind HSODBC has been desupported 15th of March and you should move to the follow up product DG4ODBC V11. This requires in your case to apply the database patchset AND to apply also the compatibility patch 5965763.
This discussion has been closed.