|
-
You do not have anything in WHERE clause to indicate that you are selecting records for one day.
You can use nested select statement for each day e.g.
select req_status,
(select count(*) from sample where req_status=1 and TRUNC(SENT_DATE)=TRUNC(sysdate)),
count(distinct(req_id)) as REQ_TODAY, MIN(to_char(SENT_DATE,'DD-MON-YY - HH:MI:SS')) as Min_sent_date,
MAX(to_char(SENT_DATE,'DD-MON-YY - HH:MI:SS')) as Max_sent_date,'1-NEW Command' Meaning_of_Status from sample
where sent_date like sysdate
and req_status=1 group by req_status
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|