Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Group resultset day by day

Group resultset day by day

From: Juliano.net <juliano.net_at_gmail.com>
Date: 14 Sep 2006 12:44:13 -0700
Message-ID: <1158263053.676554.30270@m73g2000cwd.googlegroups.com>


Hi, I'm searching for a better way to do a procedure that SELECTs some data of a specific month and bring the resultset with the value grouped day by day.

My tables:

TBL_Activity



ID_Activity INT
NM_Activity VARCHAR

TBL_WorkingTime


ID_WorkingTime
DT_DateTime
NR_HoursSpent
ID_Activity

So, I need to get from all the activities (TBL_Activity) the sum of the NR_HoursSpent grouped by every month day.

I need to have a resultset like this:

ID_Activity | NM_Activity | Day 01 | Day 02 | Day 03 | and son on, up to the last month day | Day 31

And for every Day, I get the sum of the NR_HoursSpent for that day.

How can I do this? Received on Thu Sep 14 2006 - 14:44:13 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US