Oracle driver does not translate "LIMIT 1" statement.
I was implementing redis module and got following error:
PDOException: SELECT source, language FROM {url_alias} WHERE alias = :alias AND language IN (:language_0, :language_1) ORDER BY language ASC, pid DESC LIMIT 1 (prepared: SELECT source, language FROM "URL_ALIAS" WHERE alias = :alias AND language IN (:language_0, :language_1) ORDER BY language ASC, pid DESC LIMIT 1 ) e: SQLSTATE[HY000]: General error: 933 OCIStmtExecute: ORA-00933: SQL command not properly ended (/usr/src/php/ext/pdo_oci/oci_statement.c:148) args: Array ( [:alias] => user/logout [:language_0] => en [:language_1] => und ) in drupal_lookup_path() (line 175 of /var/www/html/sites/all/modules/redis/redis.path.inc).
For testing in include/database/oracle/database.inc in function escapeCompatibility($query) I removed "LIMIT 1" with empty string and it worked. So we need to translate "LIMIT 1" statement properly.
Comments
Comment #2
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!