Page 1 of 1

[2.0.0-beta 2] column 'true' does not exist

Posted: Sat Jun 14, 2014 6:11 pm
by rohdef
I just did a clean update from 1.7.3 to 2.0.0-beta-2. The front end works fine, even with my heavily customized theme etc., so far so good. But when accessing admin I get the following error:

Code: Select all

== TESTING ERROR MODE ==


Fatal error:  Uncaught exception 'ErrorException' with message 'pg_query(): Query failed: ERROR:  column "true" does not exist
LINE 35:                     WHERE isdraft = "true" AND e.timestamp <...
                                             ^' in /usr/home/rohdef/www/armchair/include/compat.inc.php:126
Stack trace:
#0 [internal function]: errorToExceptionHandler(2, 'pg_query(): Que...', '/usr/home/rohde...', 222, Array)
#1 /usr/home/rohdef/www/armchair/include/db/postgres.inc.php(222): pg_query(Resource id #22, 'SELECT DISTINCT...')
#2 /usr/home/rohdef/www/armchair/include/functions_entries.inc.php(434): serendipity_db_query('SELECT DISTINCT...', false, 'assoc')
#3 /usr/home/rohdef/www/armchair/include/admin/overview.inc.php(89): serendipity_fetchEntries(false, false, 4, true, false, 'timestamp DESC', 'isdraft = "true...')
#4 /usr/home/rohdef/www/armchair/serendipity_admin.php(228): include('/usr/home/rohde...')
#5 {main}
  thrown in /usr/home/rohdef/www/armchair/include/compat.inc.php on line 126

Re: [2.0.0-beta 2] column 'true' does not exist

Posted: Sat Jun 14, 2014 6:19 pm
by rohdef
The bug is in include/admin/overview.inc.php line 88, the query should use single quotes, not double, since double quotes in posgresql means a column.

Re: [2.0.0-beta 2] column 'true' does not exist

Posted: Tue Jun 17, 2014 12:24 pm
by garvinhicking
Hi!

Many thanks, just committed your fix!

Regards,
Garvin