Subject | Re: AW: [firebird-support] Problem Select sum .. in select |
---|---|
Author | Doug Chamberlin |
Post date | 2010-01-29T17:12:05Z |
On 1/29/2010 11:25 AM, Olaf Kluge wrote:
select sum(value) from tableB where person-id in (select id from tableA
where group = 1)
or try
select sum(value) from tableB where exists (select id from TableA where
TableA.person-id = TableB.id and TableA.group = 1)
--
Doug C.
-----
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
> select sum(value) from tableB where person-id in ( FOR select id fromJust remove the "for":
> tableA where group = 1) - the "for" doesn't work
select sum(value) from tableB where person-id in (select id from tableA
where group = 1)
or try
select sum(value) from tableB where exists (select id from TableA where
TableA.person-id = TableB.id and TableA.group = 1)
--
Doug C.
-----
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?