Query Name: searchNews
SQL:
SELECT
news_id,
COALESCE(news_title, '??') AS titel,
news_title AS titel,
news_date AS datum,
artist_lname AS kunstenaar,
exhibition_title AS expositie,
artist_id,
exhibition_id
FROM news
LEFT JOIN artist ON (artist_id = news_artist_id AND artist.language_iso_code = news.language_iso_code)
LEFT JOIN exhibition ON (exhibition_id = news_exhibition_id AND exhibition.language_iso_code = news.language_iso_code)
WHERE
news.language_iso_code = 'en'
AND
( coalesce(news_title::text, ''::text) ILIKE '%%' ) AND true
ORDER BY "titel" DESC
;
Error Occured:
Errornum: 256 Errortype:
Errormsg: ERROR: ORDER BY "titel" is ambiguous
Scriptname: /var/virtuals/galeriewit.nl/www/inc/database/inc-databasequery.php
Scriptlinenum: 74