Page 1 of 1

Program gets stuck when connecting to DB

Posted: Mon 18 Jun 2007 07:43
by bij
A customer of ours has the follwing problem with the direct connection of ODAC V6.05.0.7 (Delphi 2006) to Oracle V7.1.3.2.0 run on a VAX server. There are two DBs on two servers that are set up the same way. The connection to one of them works fine. But if they try to connect to the other one, the program will not connect, use 100% CPU and will not respond any more. No error or anything returns. The Event BeforeConnect fires but ConnectChange doesn't.

Do you have any idea what can cause this behavior?

Cheers
bij

Posted: Tue 19 Jun 2007 07:46
by Plash
Please specify whether you can connect to the database when the Direct option of the TOraSession component is set to False.

Posted: Tue 19 Jun 2007 07:49
by bij
If Direct is set to False the connection to the DB works fine.

Posted: Wed 20 Jun 2007 08:49
by Plash
We could not reproduce the problem. Please send to odac*crlab*com a complete small sample that demonstrates the problem, including script to create server objects.

Posted: Wed 20 Jun 2007 09:17
by bij
I am sorry, but this is not possible. The problem just occurs at one of our customers databases. We cannot reproduce the problem in our developing environment either. Is there another possibility how to provide you with further information on where to find the problem? Is there a function to log detailed debugging information? Do you have an idea what database configuration could possibly cause this behavior?

Posted: Fri 22 Jun 2007 08:47
by Plash
ODAC supports Oracle starting with 7.3 version. Therefore problem can occur because you use ODAC with Oracle 7.1.

Posted: Wed 30 Jan 2008 20:01
by YourFather
I'm experiencing same problem, but using ODAC 4.00.0.1 Net Edition w/Delphi Enterprise 7.
I've an app wich connects to one in five distinct servers (say 10.1.1.2:1521:ORCL / 10.1.1.3:1521:ORCL / 10.1.1.4:1521:ORCL / 10.1.1.5:1521:ORCL). In all servers exists a single user USER1 with same password for all servers.
In a form i've a combobox with this information...
I've a datamodule with an orasession (dbApp) and an oraquery (qryApp)...

Steps:
1. I'm select server 1 to connect.
2. Call dbApp.Disconnect.
3. Set dbApp.ConnectStr := ...
4. Call dbApp.Connect.
5. Connection stablishes OK
6 I'm select server 2 from combobox
7. Call dbApp.Disconnect.
8. Set dbApp.ConnectStr := ...
9. Call dbApp.Connect. My app frezees here.

I tried other alternatives:
- Destroy dbApp after select another server, create again, setting info and connecting. Fails.

- Creating datamodule after selection of another server, create, setting info and connecting. Fails.

Posted: Wed 30 Jan 2008 20:07
by YourFather
Additional info:
I'm using OraSession.Options.Net := true
Our servers run Oracle 9i on Windows 2003 Server or HP-UX v11
If i run my app with single connection, it works fine...

Posted: Fri 01 Feb 2008 09:14
by Plash
Try to call FreeNet procedure after disconnecting. (You need to add OraNet unit to 'uses' clause.)

Posted: Fri 01 Feb 2008 21:43
by YourFather
I tried with FreeNet proc, but don't works.
Throws a "Need Oracle Call Interface" exception on first selection.
Second selection works fine.
Third selection freezes app.

* Edit *
Calling InitNet procedure before Connect procedure, don't throws an exception, but, app freezes over an over...

Posted: Wed 06 Feb 2008 08:32
by Plash
You can try to upgrade ODAC. Please check if the problem occurs with the last ODAC version (6.25.1.13).