Hi,
First I am sorry if I posted at the wrong place. Now onto the problem:
I am developing a web app with CakePHP with Oracle backend on Windows box, the development was initially done in CodeIgniter, and recently we decided to migrate to CakePHP.
The Oracle server is located at the different subnet. I am able to connect Cake to the remote server no problem, I set up some simple model, view and controller. However, when I am trying to access one of the controller. e.g. http://www.example.com/facilities/, it takes a while loading the page, and after 30 seconds the script times out.
After lotsa debugging, I found out that these lines are causing the problem.
cake/libs/model/datasources/dbo/dbo_oracle.php:448
$sql = 'SELECT view_name AS name FROM all_views UNION SELECT table_name
AS name FROM all_tables';
if (!$this->execute($sql)) {
return false;
}
From my understanding, Cake is trying to fetch all tables in the database and associate it with the Model, when I try to run the above query on sqldeveloper, I got 3.7k+ result and I think it's slowing it down to the point where the script times out.
Is there any workaround to this?
Thank's in advance.