Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here


Connecting to a Sybase 12.5 DB

Connecting to a Sybase 12.5 DB

Connecting to a Sybase 12.5 DB

I am having problems connecting my Visual Basic 6 project to a Sybase 12.5 database, I want to code it so that a DSN is not needed.

When using this code,

conn.Open "Driver={SYBASE SYSTEM 11};" & _
           "Srvr=wwhbsdb1,5555;" & _
           "DB=AML;" & _
           "Uid=myUsername;" & _

I get the error,

-2147467259 - [INTERSOLV][ODBC SQL Server driver][SQL Server]ct_connect(): directory service layer: internal directory control layer error: Requested server name not found.

And when attempting to use a different driver with this code,

conn.Open "Driver={SYBASE ASE ODBC Driver};" & _
"Srvr=wwhbsdb1,5555;" & _
"DB=AML;" & _
"Uid=myUsername;" & _

I get the error,

-2147467259 - [MERANT][ODBC Sybase ASE driver]Insufficient information to connect to the data source.

I am getting really stuck with this? I have re-installed Sybase 12.5 because I thought I had the wrong drivers, is there an issue here? What driver should I have displayed and also reference in ODBC Administrator > Drivers?

N.B. The full Sybase DB version is Adaptive Server Enterprise/12.5.3/EBF 13327 ESD#7/P/RS6000/AIX 5.1/ase1253/1951/64-bit/FBO/Fri Mar 24 04:52:26 2006

RE: Connecting to a Sybase 12.5 DB

try this:

instead of using the computer name (for the srvr part), try using the IP Address for the database server instead.


"The great things about standards is that there are so many to choose from." - Fortune Cookie Wisdom

RE: Connecting to a Sybase 12.5 DB

It was initially IP address and port in the format of


I thought this was causing problems hence using the server name. For purpose I have just tried it with IP address and I get exactly the same errors :(

P.S. Reading various resources online it states that "{SYBASE ASE ODBC Driver}" is the driver shipped with 12.5 so I don't think that's a problem.

RE: Connecting to a Sybase 12.5 DB

I have now managed to fix this. The fix is to replace the Srvr parameter with NetworkAddress. The working connection string is,

conn.Open "Driver={SYBASE ASE ODBC Driver};" & _
"NetworkAddress=wwhbsdb1,5555;" & _
"DB=AML;" & _
"Uid=myUsername;" & _

I managed to find this after extensive searching online. Additional info posted was that "This was a major change in the ODBC driver. It does not require Open Client
to access the ASE."

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close