warning: pg_query() [function.pg-query]: Query failed: ERROR: for SELECT DISTINCT, ORDER BY expressions must appear in select list LINE 10: ORDER BY n.changed DESC LIMIT 4 OFFSET 0 ^ in /_ar0data/www/drp.dev.polit.ru/public_html/includes/database.pgsql.inc on line 139.
user warning: query: SELECT DISTINCT(images.fid), f.filepath as path, n.nid, images.data FROM (SELECT nid,field_pic_fid as fid, field_pic_data as data FROM content_type_article WHERE field_pic_fid IS NOT NULL UNION SELECT nid,field_pic52_fid as fid, field_pic52_data as data FROM content_type_article WHERE field_pic52_fid IS NOT NULL) as images LEFT JOIN node n ON n.nid = images.nid LEFT JOIN files f on f.fid = images.fid ORDER BY n.changed DESC LIMIT 4 OFFSET 0 in /_ar0data/www/drp.dev.polit.ru/public_html/sites/all/modules/imagefield_assist/imagefield_assist.module on line 985.

I tried to find all such queries and made a patch. But there may be more Postgres incompatibilities, I'll continue with testing.

Comments

lourenzo’s picture

Assigned: Unassigned » lourenzo
jorbot’s picture

I had the same issue, applied the patch, and now it works perfectly. Thanks!

lourenzo’s picture

I need to create a pgsql testing instance, just to check out if any other issues appear.

lourenzo’s picture

Status: Needs review » Closed (won't fix)

We're abandoning Image module dependency / querying, so the function patched soon will be removed.