Unix Technical Forum

Question on JDBC connection

This is a discussion on Question on JDBC connection within the Oracle Database forums, part of the Database Server Software category; --> Hi all, I have installed Oracle 9i database on Linux server and Oracle 9i Client on HP-UX 11 server. ...


Go Back   Unix Technical Forum > Database Server Software > Oracle Database

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-23-2008, 07:30 AM
Ursula Lee
 
Posts: n/a
Default Question on JDBC connection

Hi all,

I have installed Oracle 9i database on Linux server and Oracle 9i Client
on HP-UX 11 server. And I need to compile some .cpp and .pc files on
the UNIX environment. Questions are:

1. Basically, the .pc and .cpp and the makefile are located on the UNIX
server as the Oracle client tool. That means the compilation will take
place on the same UNIX platform.
The makefile has this Oracle path set up as
export ORACLE_HOME=/opt/oracle/product/9.2.0.1.0

Question: How can I set up the JDBC configuration, so that the
compilation can detect the database table on Linux server?

To summarize, here is the flow:


Makefile (.cpp, .pc) ---> Oracle Client 9i on ---> Oracle 9i database
(Use its libraries, running on UNIX) (on Linux)

Table is on Linux server and .pc file requires those for compilation.

2. Do I require to set up the tnsnames.ora file under /network/admin/ ?
I use this for Windows client, but never try this client tool on UNIX
server.

3. Do I have to include anything in the Makefile beside this Oracle
path 'export ORACLE_HOME=/opt/oracle/product/9.2.0.1.0'
This path will point to the library files on Oracle Client, but what
about the database path, include that in Makefile??

Regards,
Ursula

Regards,
Ursula

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-23-2008, 07:33 AM
Harald Maier
 
Posts: n/a
Default Re: Question on JDBC connection

Ursula Lee <ursula.lee@thales-is.com> writes:

> Makefile (.cpp, .pc) ---> Oracle Client 9i on ---> Oracle 9i database
> (Use its libraries, running on UNIX) (on Linux)
>
> Table is on Linux server and .pc file requires those for compilation.
>
> 2. Do I require to set up the tnsnames.ora file under /network/admin/
> ? I use this for Windows client, but never try this client tool on
> UNIX server.


Yes, if you want to connet to the server then you have to setup the
tnsnames.ora file as under Windows.

>
> 3. Do I have to include anything in the Makefile beside this Oracle
> path 'export ORACLE_HOME=/opt/oracle/product/9.2.0.1.0'
> This path will point to the library files on Oracle Client, but what
> about the database path, include that in Makefile??


As far as I can see you will connect via the Oracle*Net protocol, so
it's not necessary to specifiy an additional database path. For
accessing the database tables it's enough if you specifiy the service
name that you have before defined in the tnsnames.ora file.

Proc allows you too to precompile the files without accessing the
database. But personally, I don't like this.

Harald
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 08:05 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com