Solved

Cannot connect to Oracle 9i Server with Oracle 9i Client using Visual Basic ADO's 2.1

Posted on 2004-08-10
7
1,620 Views
Last Modified: 2008-02-01
We are Running into a problem Connecting to the Oracle 9i database with Oracle 9i Client using Visual Basic 6.0 and ADO's.

We have tried the the following drivers and all of them seem to fail at some point or other. Here is a description of the drivers and error messages

MS ODBC for Oracle using Connection String

Unable to Execute StoredProcedures with Paramters using ADO.
Error # 3265:Item cannot be found in the collection corresponding to the requested name or ordinal.

MS ODBC driver for Oracle using DSN with Oracle 9i Client
Unable to Execute StoredProcedures with Paramters using ADO.
Error: [Microsoft][ODBC driver for Oracle][Oracle]ORA-06502: PL/SQL: numeric or value error: character string buffer too small ORA-06512


Oracle in ORAHOME using DSN and ADO
Unable to Execute StoredProcedures with Paramters using ADO.
Throws an error when refresh parameters is called.

Can some body please help!!!!!!!!!!!!!!!!!!!!1

Thanks in advance...
Shubz




0
Comment
Question by:shubz
7 Comments
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 11770268
Can you post the procedure header/interface: the list of parameters with their datatypes etc?

Have you also tried to install the Oledb provider from Oracle and use that one?
I had good results with that one, better than with the ODBC of microsoft and the one from Oracle.
Basically, I either had Bugs or Bad Performance using ODBC drivers, and switching to OleDB solved those problems.

CHeers

0
 

Expert Comment

by:j79h110
ID: 11774266
Humm,

You should try to connect via the "Test Connection" button, in the Oracle ODBC Driver Configuration window.  Please do the following and then let me know what happens:

1.  Open the control panel.
2.  Open the Administrative Tools folder.
3.  Double-click the Data Sources (ODBC)
4.  For ease of use just make a user DSN, left-click the User DSN tab
5.  Left Click the Add button.
6.  Scroll down the list until you see Oracle in OraHome92 <<what ever you named the oracle home to.
7.  Left-click the driver and then left-click the Finish button.
8.  Type "Test" in the source name, whatever the TNS entry is in the TNS Service Name field, and your user id in the User Id field.
9.  Left click the Test Connection button.
10. Enter your password and click ok...
11. If your connection fails here please let me know what the error message is.

Thanks,
JohnsterMonster

PS If you are failing here... it may be a good time to check the client out as well.  Open a cmd prompt and do the following:

c:\>tnsping <<tnsname_entry_goes_here>>
and
c:\>sqlplus /nolog
sql> connect username/password@<<tnsname_entry_goes_here>>

Example:
C:\Documents and Settings\jmharper>tnsping oratst

TNS Ping Utility for 32-bit Windows: Version 9.2.0.1.0 - Production on 11-AUG-2004 09:14:57

Copyright (c) 1997 Oracle Corporation.  All rights reserved.

Used parameter files:
C:\oracle\ora92\network\admin\sqlnet.ora


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = oratst)(PORT = 1521))) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ORATST)))
OK (20 msec)

C:\Documents and Settings\jmharper>

and
C:\Documents and Settings\jmharper>sqlplus /nolog

SQL*Plus: Release 9.2.0.1.0 - Production on Wed Aug 11 09:15:39 2004

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

SQL> connect lang_test/abc123@oratst
Connected.
SQL>
0
 

Expert Comment

by:j79h110
ID: 11774316
BTW - Your error message is this:

ORA-06512: at stringline string
Cause: Backtrace message as the stack is unwound by unhandled exceptions.
Action: Fix the problem causing the exception or write an exception handler for this condition. Or you may need to contact your application administrator or DBA.

Thanks again,
JohnsterMonster
0
 

Author Comment

by:shubz
ID: 12091695
I am sorry, but none of the anwers above have resolved my issue. I am very grateful to angelIII {http:#11770268} & j79h110 {http:#11774266}, but i would prefer not to give any points.

Thanks.
0
 
LVL 1

Accepted Solution

by:
GhostMod earned 0 total points
ID: 12118953
PAQed - no points refunded (of 100)

GhostMod
Community Support Moderator
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Data center mess 4 79
Working with SharePoint Data 8 53
Question about consuming GB from Comcast 5 53
Error Creating Foreign Keys in SQL Database 7 34
CCModeler offers a way to enter basic information like entities, attributes and relationships and export them as yEd or erviz diagram. It also can import existing Access or SQL Server tables with relationships.
These days, all we hear about hacktivists took down so and so websites and retrieved thousands of user’s data. One of the techniques to get unauthorized access to database is by performing SQL injection. This article is quite lengthy which gives bas…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question