Subject | Re: complex select |
---|---|
Author | Aage Johansen |
Post date | 2003-02-15T22:09:07Z |
"duilio_fos " wrote:
GROUP BY.
select distinct A.mat, A.nome
from tb_per A join tb_emq B on A.mat = B.mat
where A.turni_sn <> "N"
...
group by ?.prog
--
Aage J.
> ...I think you can (at least in some ways).
> Going back to my SELECT, some parts of the code could well be written
> as different SPs, but I cannot use SPs in a SELECT, can I ?
> Is there a way to take a complex SELECT and make it shorter andYou could change to explicit join syntax, and qualify the field name in the
> clearer ?
GROUP BY.
select distinct A.mat, A.nome
from tb_per A join tb_emq B on A.mat = B.mat
where A.turni_sn <> "N"
...
group by ?.prog
--
Aage J.