Results 1 to 3 of 3
  1. #1
    Join Date
    Apr 2006

    Unhappy Unanswered: Need guidance with report requirements

    Hello experts,

    I am building a stored procedure using a number of case statements. I am using ref cursor to pull and display the data. Works great. However, I need to provide on a report from an oracle database table - a count(from a million records) of tickets that had a certain status for the day. No problems with this. But then I need to display just the details of those tickets. So if there was four tickets of the million records for that data only show me the details for the 4 tickets for that day. Then below this count, and details I would need to show the count for the year and then the details for those yearly records. It almost seems like I am building individual subreports(subsections) for the requirements of the report but displaying all these subsets of data on one report. Any ideas or lead me in the right direction. If we can continue using the case statements that would be great. I am using crystal reports and can easily use subreports but do not want to do this. Using oracle 9.2. If you need me to show the code please advise. Thanks experts.

  2. #2
    Join Date
    Jun 2003
    West Palm Beach, FL


    Yes, follow these instructions.

    The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb

  3. #3
    Join Date
    Mar 2002
    Reading, UK
    Isnt it a case of just using union all to join the result 4 queries?

    select count(*), null... from ...<record for that day>
    union all
    select * from ...<record for that day>
    union all
    select count(*), null...from ...<record for that year>
    union all
    select * from ...<record for that year>
    You would of course have to had some null columns to the count queries so that the number and datatype for the count query match your detail query. Probably also worth adding queries to put subheadings in.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts