Solved

oci_connect and oracle 9i

Posted on 2014-11-12
17
221 Views
Last Modified: 2014-11-14
Hi,

I am using oci_connect to connect to an oracle 11 without problems, but oci_connect don't work with 9i, what i can do and how i can solve this problem?
0
Comment
Question by:joyacv2
  • 9
  • 8
17 Comments
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438293
I don't think it is oci_connect.  Likely the version of the client you have installed.

To connect to a 9i database, you'll need a pretty old Oracle client version.  Sorry but I don't know the exact version.
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40438394
The oci_connect in php docs indicates that requires 10 and over
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438405
Version 10g should connect to a 9i database.  I would expect 11g and higher to have problems.

What version do you have installed?

Finding a 10g client version is going to be problematic if you don't have it in-house somewhere.  Oracle has removed the 10g software from their site.
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40438482
i have the oracle 11 client on an ubuntu server and use php to connect to databases, so what i can do?
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438493
I'm trying to find information on if the 11g client will connect to a 9i database.

While I look, what error message are you getting?
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438519
Check out this document on Oracle Support:
Client / Server Interoperability Support Matrix for Different Oracle Versions (Doc ID 207303.1)

I cannot post any of the information if you don't have access to Oracle Support.
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40438555
couldn't found driver
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438574
Now that I've re-read the question, I might have misunderstood the problem.

Just to make sure I understand the problem:
You have an 11g client installed and are trying to talk to a 9i database using oci connect?
or
You have a 9i client installed trying to connect to a 9i database?
0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 
LVL 1

Author Comment

by:joyacv2
ID: 40438710
the first one, 11 client trying to talk to 9i database using oci_connect
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438773
Since it states it cannot find the driver, I wonder if there is an issue with the install.

Was this a new install or the same machine doing connections to both an 11g and 9i database and the 11g works?
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40438946
the connection always is to an 11 oracle database, this is the first time that I try to 9i, but which alternative i have if oci_connect cannot be used?
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40438963
I'm not a PHP person.

If the same app on the same server can connect to an 11g database and all you change is the database you are connecting to, I would not expect a "couldn't found driver" type error.

I would expect a version incompatibility type error.

I see some posts stating that you need 10g or above for EZConnect.  I see other posts stating oci_connect will work against 9i.

Are you using EZConnect?  If so, try the old tnsnames.ora method.

If it still doesn't work, please provide the exact error.
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40438967
yes, I already try that, but don't found any tsnames explanation for ubuntu server 12.04 lts, do you know how to do that?
0
 
LVL 76

Accepted Solution

by:
slightwv (䄆 Netminder) earned 500 total points
ID: 40438983
tnsnames is an Oracle thing not an OS thing.

What is the connect string you are trying to use?

If you are using tnsnames there should be a file named tnsnames.ora on your server.  This is typically in $ORACLE_HOME/network/admin.  Where $ORACLE_HOME is the base folder where you installed the Oracle client.  You 'can' change the default but don't want to confuse the issue unless I have to.

Still not sure about your setup:
You have one server that can connect to 11g and you are trying to use that exact same server to connect to 9i and all you are doing is changing the connect strings?
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40439048
i have an ubuntu server 12.04 lts, with php, 11 oracle client, pci8 that connects to another server that have 11 oracle database, and i am trying to connect to another server that have a 9i oracle database
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40439055
OK, then the same server that works connecting to 1g database is failing when trying to connect to a 9i database.

That tells me that the client is installed correctly.

Still waiting for your connect string.
Still waiting for the exact error message.
0
 
LVL 1

Author Comment

by:joyacv2
ID: 40439073
i am out of office right now, i will give you the info as soon as i can, thank you very much!
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Suggested Solutions

Have you ever had to make fundamental changes to a table in Oracle, but haven't been able to get any downtime?  I'm talking things like: * Dropping columns * Shrinking allocated space * Removing chained blocks and restoring the PCTFREE * Re-or…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

760 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now