Trochu modifikuji Benův dotaz,
select count(distinct switch_id)
from [email protected]
where dealer_name = 'XXXX'
and creation_date between add_months(trunc(sysdate,'mm'),-1) and last_day(add_months(trunc(sysdate,'mm'),-1))
Trochu modifikuji Benův dotaz,
select count(distinct switch_id)
from [email protected]
where dealer_name = 'XXXX'
and creation_date between add_months(trunc(sysdate,'mm'),-1) and last_day(add_months(trunc(sysdate,'mm'),-1))