Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2002
    Posts
    6

    Unanswered: Problem Connecting to Oracle ODBC

    I'm trying to link into an Oracle database through linked tables so I can
    run some reports. I have setup the Oracle database in the tnsnames.ora
    file, and can access the database using SQL Plus. So my permissions and everything are there. BUT, when I try to link in using a new DNS or a direct ODBC call I get a run time error:

    COULD NOT RESOLVE SERVICE NAME

    Any suggestions? I am entering the same user ID and password I use to logon to SQL Plus.

    Thanks,

    Thomas

    ************TEST VBA CODE**********************

    Private Sub Command0_Click()
    Dim cnoracle As Connection
    Dim rsoracle As Recordset

    Set cnoracle = New Connection
    With cnoracle
    .Provider = "MSORAOLE"
    .ConnectionString = "Driver={Microsoft ODBC for ORACLE};
    ODBC; UID= UID; PWD= PWD; Server=gbv03p"
    .Open <---------- hangs on this command
    End With
    Set rsoracle = New Recordset
    rsoracle.Open "SELECT full_name FROM gv_user", cnoracle
    MsgBox rsoracle!full_name
    End Sub

    ************TNSNAMES.ORA ENTRY***************

    gbv03p = (DESCRIPTION =

    (ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = sjcds007)(PORT =1521)))

    (CONNECT_DATA = (SID = gbv03p)(GLOBAL_NAME= gbv03p.world)))

  2. #2
    Join Date
    Aug 2002
    Posts
    6
    ttt for some serious help

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •