Hi. I keep getting unknown column errors in elysia_cron_update.php

 in elysia_cron_check_version_update() (line 183 of
/var/www/openscholar/openscholar/modules/contrib/elysia_cron/elysia_cron_update.php).
PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'ec_%%' in 'where clause': select * from {variable} where name like "ec_%%" or name like "ecc_%%"; Array
(
)
 in elysia_cron_check_version_update() (line 183 of /var/www/openscholar/openscholar/modules/contrib/elysia_cron/elysia_cron_update.php).

and

1WD php: PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'elysia_cron_%%' in 'where     [error]
clause': select * from {variable} where name like "elysia_cron_%%"; Array
(
)
 in elysia_cron_check_version_update() (line 28 of
/var/www/openscholar/openscholar/modules/contrib/elysia_cron/elysia_cron_update.php).
PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'elysia_cron_%%' in 'where clause': select * from {variable} where name like "elysia_cron_%%"; Array
(
)
 in elysia_cron_check_version_update() (line 28 of /var/www/openscholar/openscholar/modules/contrib/elysia_cron/elysia_cron_update.php).

Patch to follow.

Comments

jsagotsky’s picture

StatusFileSize
new1.41 KB

Here's my patch. I updated the db_query calls to db_selects and that fixed it. I'm not sure why it makes a difference.

gotheric’s picture

Assigned: Unassigned » gotheric
Status: Active » Fixed

I think the problem is using the double quotes " instead of the single quote ' for string comparison in SQL query.

I changed the query to use the single quote (i prefer not to apply the patch because that's only for D7, and now elysia_cron_update.php is drupal version independent).

Let me know if it keeps giving error in next version.

Thank for the report

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

SebCorbin’s picture

Issue summary: View changes
Status: Closed (fixed) » Active

The 7.x-2.1 release seems to be missing this fix.

There is no 7.x-2.1 in the git repo too, would it be possible to make a new 2.2 release with a proper tag?

regilero’s picture

+1

kala4ek’s picture

Version: 7.x-2.1 » 7.x-2.x-dev
Assigned: gotheric » Unassigned
Status: Active » Closed (outdated)