?
Solved

oci_connect and oracle 9i

Posted on 2014-11-12
17
Medium Priority
?
262 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 9
  • 8
17 Comments
 
LVL 77

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 77

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
Don't Cry: How Liquid Web is Ensuring Security

WannaCry is just the start. Read how Liquid Web is protecting itself and its customers against new threats.

 
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 77

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 77

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 77

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
 
LVL 1

Author Comment

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

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 77

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 77

Accepted Solution

by:
slightwv (䄆 Netminder) earned 2000 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 77

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

WordPress Tutorial 2: Terminology

An important part of learning any new piece of software is understanding the terminology it uses. Thankfully WordPress uses fairly simple names for everything that make it easy to start using the software.

Question has a verified solution.

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

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses

765 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