Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Problem Connecting to Oracle ODBC

Problem Connecting to Oracle ODBC

From: Mitchell, Thomas [RICH1:3878:EXCH] <thommit_at_americasm01.nt.com>
Date: Tue, 18 Mar 2003 14:33:42 -0600
Message-ID: <b57vok$mmg$1@zcars0v6.ca.nortel.com>


I'm trying to link into an Oracle database through MS Access 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)))
Received on Tue Mar 18 2003 - 14:33:42 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US