I am using Drupal 7.15 in Windows 7 with Oracle 11g Express Edition.
While enabling some modules, at certain point, I am getting the following error:
The website encountered an unexpected error. Please try again later.
DatabaseTransactionNoActiveException: in DatabaseConnection->rollback() (line 1019 of ..\includes\database\database.inc).
And after that, site is not accessible, until I disable the some modules manually, which I have tried to install at that time and then using update.php restore the menu system.
I dig down the problem and find out that it could be related to menu system.
I have trapped the error of the following SQLs in the menu.inc
$result = db_select('menu_links', NULL, array('fetch' => PDO::FETCH_ASSOC))
->fields('menu_links', array(
'link_path',
'mlid',
'router_path',
'updated',
))
->condition(db_or()
->condition('updated', 1)
->condition(db_and()
->condition('router_path', $paths, 'NOT IN')
->condition('external', 0)
->condition('customized', 1)
)
)
->execute();
$result = db_select('menu_links')
->fields('menu_links')
->condition('router_path', $paths, 'NOT IN')
->condition('external', 0)
->condition('updated', 0)
->condition('customized', 0)
->orderBy('depth', 'DESC')
->execute();
After trapping I am getting the following error:
OCIStmtExecute: ORA-01795: maximum number of expressions in a list is 1000
It means, $path variable has more then 1000 items, and "NOT IN" clause has a limit of 1000 expression, unless you use SQL which may generate more then 1000 expressions.
How to fix that?
Comments
Comment #1
aaaristo commentedlook at the oracle_escape_long_in function in the 6.x driver... i should include that in 7.x
Comment #2
aaaristo commentedComment #3
aaaristo commentedCommited, can you try the dev release?
Comment #4
yosriy commentedHello,
I have same problem and this is not fixed on the latested version for now : 7.24
and I get : ORA-01000 maximum open cursors exceeded
As detailed on https://drupal.org/comment/359202#comment-359202
I already increased open_cursors as mentionned on :
http://www.stanford.edu/dept/itss/docs/oracle/10g/server.101/b10739/crea...
=> Via ToadForOracle :
sho parameter open_cursors
open_cursors integer 2000
I am available for more details,
For now no solution unfortunately...
Thnx,
Yosri
Comment #5
aaaristo commentedhave you tried the -dev release?
Comment #6
fastturtle commentedHello,
I have a drupal 7.31 installation on IIS7.5/WIN2008R2 and Oracle11g database. I am using the oracle driver.
I have installed the PM module and when I am trying to use it I am getting the same error as the issue's title.
Type php
Date Wednesday, October 1, 2014 - 13:56
User admin
Location http://localhost/testdrupal731/node/add/pmproject?render=overlay&render=...
Referrer http://localhost/testdrupal731/node/add/pmproject?render=overlay
Message DatabaseTransactionNoActiveException: in DatabaseConnection->rollback() (line 1038 of C:\inetpub\wwwroot\testdrupal731\includes\database\database.inc).
Severity error
Hostname ::1
Operations
Also I have test this with both recommended release and development release of oracle driver.
I have reported this issue also to the PM module's issues: https://www.drupal.org/node/2347685
Is there any possible solution to this?
Thanks in advance.
Comment #7
metallized commentedHi i'm having the same issue using the 7.x-1.12+5-dev version of driver, there is news about this?, any help is much appreciated.
Comment #8
metallized commentedComment #9
metallized commentedHi meanwhile i do this to the menu.inc file, I hope that soon there a patch:
Comment #10
metallized commentedComment #11
yesmathew commentedThanks #9, your trick worked on version 7.44. For me update.php was also not working with Oracle 11g, so following code fix on 2 files worked for me;
Code fix on include/update.inc -
And code fix on include/menu.inc -
Comment #12
punch commentedInstead of changing the menu.inc try this: https://www.drupal.org/node/2761515
Comment #13
bohartD7 reached its EOL back in January 2025, and there is no active release for D7 for this module anymore.
Development or support is not planned for D7. All D7-related issues are marked as outdated in a bunch.
Everyone can apply the patches/suggestions above (not tested by the maintainers, tested by the community) to their D7 projects.
If the issue remains relevant for D10+ versions, merge requests with proposed solutions for a new module version (D10+) are welcome in a new follow-up issue.
Thanks!