Received: from www.nettverk.no (pc237.kf.kommorg.no [193.212.171.237] (may be forged)) by postgresql.org (8.11.3/8.11.4) with ESMTP id f78Cvc679486 for ; Wed, 8 Aug 2001 08:57:38 -0400 (EDT) (envelope-from andreak@officenet.no) Received: from localhost.localdomain ([127.0.0.1] helo=officenet.no) by www.nettverk.no with esmtp (Exim 3.32 #2) id 15UStd-0006s4-00 for pgsql-sql@postgresql.org; Wed, 08 Aug 2001 14:57:13 +0200 Message-ID: <3B713729.62D20CCB@officenet.no> Date: Wed, 08 Aug 2001 14:57:13 +0200 From: Andreas Joseph Krogh X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.2.17-21mdksecure i686) X-Accept-Language: en MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: Referencing named attribute in where clause doesn't work with 7.1.2? Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200108/117 X-Sequence-Number: 4338 Hi, this is my first post to this list so please... I have problems getting this query to work, any ideas? select article.title_text_key, (select on_text.text_value from on_text where on_text.text_key = title_text_key AND NOT title_text_key is NULL AND on_text.lang_id = (select code.id from code, code_group where code.code_group_id = code_group.id AND code_group.description = 'lang' AND code.code_key = 'lang.NO' ) ) as title_text_value from article where NOT title_text_value is NULL; ERROR: Attribute 'title_text_value' not found Issuing the same query without the where-clause does work tho, but return tupples with null in them which I don't want. -- Andreas Joseph Krogh