Re: [GENERAL] wrong query result

2008-04-09 Thread Albe Laurenz
josep porres wrote: > select clau, lecact-lecant as m3, m3any, ta, tc, 3 as mesos, persones, true > as clavegueram > from fac_abonats > where clau in (select clau from tmp_claus_prova) > order by clau > > the thing is that the result of the query returns the same > number of rows as the table fa

Re: [GENERAL] wrong query result

2008-04-09 Thread Martijn van Oosterhout
On Wed, Apr 09, 2008 at 10:20:18AM +0200, josep porres wrote: > At the end I've realized that there is no column named 'clau'. It has > another name. > So the subselect query is wrong, if I execute it alone, an error appears > The question is: > Is it a normal behaviour? Because I think that if

Re: [GENERAL] wrong query result

2008-04-09 Thread Richard Huxton
josep porres wrote: select clau, lecact-lecant as m3, m3any, ta, tc, 3 as mesos, persones, true as clavegueram from fac_abonats where clau in (select clau from tmp_claus_prova) order by clau At the end I've realized that there is no column named 'clau'. It has another name. The question is:

[GENERAL] wrong query result

2008-04-09 Thread josep porres
Hi I just want to let you know one thing. By the way, I'm running Postgres 8.3.1 on windows I was making a query using pgadmin: select clau, lecact-lecant as m3, m3any, ta, tc, 3 as mesos, persones, true as clavegueram from fac_abonats where clau in (select clau from tmp_claus_prova) order by c