[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
Re: Group by
Here is a "group by" that I have used:
begin-SELECT on-error=sql_error
lm13.business_unit &lm13.business_unit
lm13.contract_num_pc &lm13.contract_num_pc
lm13.contract_line_num &lm13.contract_line_num
min(lm13.resource_amount) &lm13.resource_amount
do some_routine
from ps_pc_intfc_lm_tao lm13,
ps_pc_cont_lmt_vw pclv4
where lm13.analysis_type = 'BIL'
and lm13.business_unit = pclv4.business_unit
and lm13.contract_num_pc = pclv4.contract_num_pc
and lm13.contract_line_num = pclv4.contract_line_num
and lm13.process_instance = pclv4.process_instance
and lm13.process_instance = #prcs_process_instance
group by lm13.business_unit,
lm13.contract_num_pc,
lm13.contract_line_num
having min(lm13.resource_amount) > 0
end-select
Bruno Coquemont <bcoquemont@ICDC.CAISSEDESDEPOTS.FR> on 10/25/99 12:25:57 PM
Please respond to SQR-USERS@list.iex.net
To: Multiple recipients of list SQR-USERS <SQR-USERS@list.iex.net>
cc: (bcc: Rick Creel/IT/Aon Consulting)
Subject: Group by
Hi,
Can I put a "group by" in a begin-select paragraph ? If no, how can
I do ?
Thanks, Bruno.