|
-
Aug 22nd, 2000, 08:54 AM
#1
Thread Starter
Addicted Member
Aye Up Everybody,
I've written a small application to transfer data from .txt file on a server into an axcess database, all was good and well, But now I need to use the same prgram to connect to an oracle database and I just can't get it to work.
I'm using the following line of code ( The oracle database also has a username and password which will need to be incorporated aswell???)
Set DBconnect = Workspaces(0).OpenDatabase("D:\Oracle\Ora81\BIN\SQLPLUSW.EXE ")
The error message saise "unreccognisable database format"
Whatever the hell that means
Cheers 'n' beers ( and a big shout out to the manchester massif in de area - SKEEN
"It wasn't the booze that made me snooze, It was the Gin that did me in!"
-
Aug 22nd, 2000, 10:13 PM
#2
Hyperactive Member
Assuming you have Oracle drivers installed (if not, see MSDN Q140255), here's an ADO snippet to open your connection:
Code:
'Replace <User ID>, <Password>, <Server> with appropriate parameters.
Dim Conn As String
Dim Cn As ADODB.Connection
Conn = "UID=*****;PWD=*****;driver={Microsoft ODBC for Oracle};SERVER=dseOracle;"
Set Cn = New ADODB.Connection
With Cn
.ConnectionString = Conn
.CursorLocation = adUseClient
.Open
End With
A different tact that will save you time, should your Oracle table have less than 500K rows, would be to setup a DSN on your local machine and then link the Oracle table(s) within your existing Access db; then use your current code, as is.
Hope this helps 
-
Aug 23rd, 2000, 06:15 AM
#3
Thread Starter
Addicted Member
"It wasn't the booze that made me snooze, It was the Gin that did me in!"
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|