🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.interbase.sql
Article #10966

Re: Pre-compile error problem

#10966
From: Wayne Niddery [TeamB]
Date: Wed, 01 Jan 2003 17:14
29 lines
2160 bytes
"The DeerBear" <rainaple@tin.it> wrote in message
news:3e125625$1@newsgroups.borland.com...
>
> Using IBExpert PE, precompiling has problems with the following query:
>
> select accounts.user_id,accounts.title,
> accounts.first_name,accounts.last_name,accounts.user_id,roles.user_role
from
> ACCOUNTS acc
>       INNER JOIN ROLES R On R.user_id = Acc.user_id
>       where R.USER_ID = ( Select USER_ID From Accounts ( Where
> ACCOUNTS.USER_ID Not in ( REQ_USR_ID ) ) )
>       group by R.user_role

The set of fields specified for Group By must be the same as the set of
non-aggregate fields in the Select. This is ANSI standard. In this case you
have no aggregates (SUM, COUNT, etc) so all selected fields must also be in
the group by.

I have no idea what you are trying to do with "Not in ( REQ_USR_ID )", but I
don't believe you need the subselect either way, you should be able to
simply say " where R.USER_ID not in ...".

Explain what you are trying to get.

--
Wayne Niddery - Logic Fundamentals, Inc. (www.logicfundamentals.com)
"Democracy, without that guarantee of liberty, is merely a method of
selecting tyrants." - Alan Nitikman
Technical Details
Message-ID: <3e132284$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-01!sn-xit-08!supernews.com!telocity-west!DIRECTV!203.109.225.2!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <3e125625$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 114a0e,5649031f8df85db4
X-Google-Attributes: gid114a0e,public
X-Google-ArrivalTime: 2003-01-01 09:33:07 PST
From: "Wayne Niddery [TeamB]" <wniddery@chaff.aci.on.ca>
Newsgroups: borland.public.interbase.sql
References: <3e125625$1@newsgroups.borland.com>
Subject: Re: Pre-compile error problem
Date: Wed, 1 Jan 2003 12:14:07 -0500
Lines: 31
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
NNTP-Posting-Host: 209.50.82.158
Message-ID: <3e132284$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1041441412 209.50.82.158 (1 Jan 2003 09:16:52 -0800)
X-Authenticated-User: wniddery
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-01!sn-xit-08!supernews.com!telocity-west!DIRECTV!203.109.225.2!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail