[?] Remote Oracle DB

Just starting out? Need help? Post your questions and find answers here.
Machiavelli
User
User
Posts: 26
Joined: Sun May 24, 2009 2:38 pm

[?] Remote Oracle DB

Post by Machiavelli »

What do I have:
Oracle DB located in the network,
Oracle FORMS 6i with which i can connect to the database (using only login / password / db name)
I've found out that OF6i connects to 192.168.1.11:1521 to access the DB

Can I access the same DB with PB commands? Or UseODBCDatabase() / OpenDatabase() works only with local DB?
infratec
Always Here
Always Here
Posts: 7577
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: [?] Remote Oracle DB

Post by infratec »

Hi Machiavelli,

ODBC can also connect to 'remote' databases.
So if you have an ODBC driver for your Oracle database it is no problem.

Than you can use UseODBCDatabase()
and the PB database commands.

Bernd
Machiavelli
User
User
Posts: 26
Joined: Sun May 24, 2009 2:38 pm

Re: [?] Remote Oracle DB

Post by Machiavelli »

Well, i do have the driver. But i cant find anything about connecting to remote DB in the help and OpenDatabase() receives only db name, login and password as parameters, nothing about the DB host.
infratec
Always Here
Always Here
Posts: 7577
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: [?] Remote Oracle DB

Post by infratec »

Hi Machiavelli,

if you use ODBC, than you have to setup your connection inside your OS:

http://docs.oracle.com/cd/E17952_01/ref ... ndows.html

If you want to create the DSN 'on the fly' look here:
http://www.purebasic.fr/english/viewtop ... hilit=ODBC
and here
http://www.connectionstrings.com/oracle#p17

Bernd
Post Reply