Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Matrix report

partlycloudyNov 18 2013 — edited Dec 15 2013

APEX 4.2.2

Say I have a resultset with 3 columns: customer name, date and number of orders. What is the quickest and most flexible way to put this data on an APEX report such that the customers go down the Y-axis and Date goes across and each cell in the report is the number of orders. Sort of like a sparse matrix, or pivot report. Also, the aggregation level of the date should be modifable at run-time i.e. each column represents a week or a month or day with the column heading changing accordingly.

e.g. for a monthly summary,

with metrics as (

SELECT

trunc(dt,'mm') dt,

nm,

count(*)

FROM data

group by nm,trunc(dt,'mm')

)

select

nm,

max(decode(....)) c1,

max(decode(...)) c2,

...

from metrics

but I am not sure how to go about doing the max(decode(...)) to show a rolling N months of data. Similarly for weekly and daily view.

Help? Thanks

This post has been answered by fac586 on Dec 15 2013
Jump to Answer

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Jan 12 2014
Added on Nov 18 2013
3 comments
4,458 views