Re: [GENERAL] select max from subquery

2009-02-15 Thread searchelite
Oleg Bartunov wrote: > > yOn Sat, 14 Feb 2009, searchelite wrote: > >> >> Dear All >> >> i gave this kind of query >> >> select max(foo) from (select some statement) as foo >> >> but it gave me this error >> ERROR: function max(record) does not exist >> >> >> any help how i can select max val

Re: [GENERAL] select max from subquery

2009-02-14 Thread Oleg Bartunov
yOn Sat, 14 Feb 2009, searchelite wrote: Dear All i gave this kind of query select max(foo) from (select some statement) as foo but it gave me this error ERROR: function max(record) does not exist any help how i can select max value from suqbuery in main query like this: select max(fo

Re: [GENERAL] select max from subquery

2009-02-14 Thread Grzegorz Jaƛkiewicz
select max(foo.record) from ... ? -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] select max from subquery

2009-02-14 Thread Raymond O'Donnell
On 14/02/2009 11:05, searchelite wrote: > select max(foo) from (select some statement) as foo Can you post the full query? It's very hard to tell from this. Also, I think you may need to give the subquery an alias, thus: select max(foo) from ( ) s as foo Ray. --

[GENERAL] select max from subquery

2009-02-14 Thread searchelite
Dear All i gave this kind of query select max(foo) from (select some statement) as foo but it gave me this error ERROR: function max(record) does not exist any help how i can select max value from suqbuery in main query thanks -- View this message in context: http://www.nabble.com/select-