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 attaching ODBC tables with Oracle 9 driver

problem attaching ODBC tables with Oracle 9 driver

From: SonLino <sonlinoQUITAR_at_yahoo.es>
Date: Tue, 27 Jan 2004 12:38:13 GMT
Message-ID: <VYsRb.2947375$uj6.7545162@telenews.teleline.es>

Hi,

I have been trying to attach an Oracle table from Access 2000 DB without any success. Each time I try to do it, I get a MS Jet Error 3011. Table not found.
The same code source (displayed below) works fine on Oracle 8 or SQL server tables. Maybe the problem is the ODBC Oracle Driver. (version 9.02.00.00) but when I repeat the operation by using Access and its functions (right click and "attach tables" on the "Tables" menu), it works fine too.

AnyOne has any idea?

The code I have been using is:

Function pcmAdjTablaODBC()

      On Error GoTo AdjTablaODBC_Err

      Dim db As Database
      Dim tdef As TableDef
      Dim strConnect As String

      Set db = CurrentDb()
      'strConnect = "ODBC;"
      strConnect =

"ODBC;DSN=lmn_Oracle;UID=USUARIO;PWD=PASSWORD;DBQ=LMN;DBA=W;APA=T;EXC=F;FEN= T;QTO=T;FRC=10;FDL=10;LOB=T;RST=T;GDE=F;FRL=F;BAM=IfAllSuccessful;MTS=F;MDI= F;CSR=F;FWC=F;PFC=10;TLO=0;"
      Set tdef = db.CreateTableDef("pruebas")
      tdef.Attributes = DB_ATTACHSAVEPWD
      tdef.Connect = strConnect
      tdef.SourceTableName = "Rutas"
      db.TableDefs.Append tdef

AdjTablaODBC_Exit:
      Exit Function

AdjTablaODBC_Err:
      MsgBox "Error: " & Str(Err) & " - " & Error$
      Resume AdjTablaODBC_Exit

    End Function Received on Tue Jan 27 2004 - 06:38:13 CST

Original text of this message

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