On Fri, Jan 02, 2004 at 05:49:46PM +0100, Samuel Tardieu wrote:
>
> select texten, total
> from (select protocolid, count(*) as total) from ips where catid=1
^
+--- There
> group by protocolid order by pr
On Fri, Jan 02, 2004 at 05:49:46PM +0100, Samuel Tardieu wrote:
> In PostgreSQL 7.4, the following select:
>
> select texten, total
> from (select protocolid, count(*) as total) from ips where catid=1
> group by protocolid order by protocolid) as c
> inner join protocols using (protocolid)
On 3/01, Samuel Tardieu wrote:
| On 2/01, Michael Glaesemann wrote:
|
| | I'm not quite sure what you want the query to return, but you've got a
| | problem with your parentheses.
|
| I can't believe this :) I got hit by the "inner query needs to be aliased"
| message and added it to the wron
On 2/01, Michael Glaesemann wrote:
| I'm not quite sure what you want the query to return, but you've got a
| problem with your parentheses.
I can't believe this :) I got hit by the "inner query needs to be aliased"
message and added it to the wrong place and them munged the query a lot.
The c
Samuel Tardieu <[EMAIL PROTECTED]> writes:
> In PostgreSQL 7.4, the following select:
> select texten, total
> from (select protocolid, count(*) as total) from ips where catid=1
> group by protocolid order by protocolid) as c
> inner join protocols using (protocolid);
> gives the error mes
Hi Sam,
I'm not quite sure what you want the query to return, but you've got a
problem with your parentheses. You've got two FROM clauses and an INNER
JOIN, which together aren't arranged properly. I've rearranged your
query a little, but I haven't changed anything. Perhaps this'll make it
a l
In PostgreSQL 7.4, the following select:
select texten, total
from (select protocolid, count(*) as total) from ips where catid=1
group by protocolid order by protocolid) as c
inner join protocols using (protocolid);
gives the error message:
ERROR: subquery in FROM must have an alias
HIN