Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Advanced Prompt in 4.0 Universe

Status
Not open for further replies.

Dross

Programmer
Aug 16, 2001
212
US
I am not sure if this is the correct forum, but I do not see any Universe Design forums so if there is a better one to use please let me know.

I am using BO 4.0.

I built a Universe that is not complex at all, but I do want to have the users use 1 date filter for several date fields and date lengths. For instance I have several dates to use that are Start Date, Scheduled Date, Admitted Date Reviewed Date...etc. and several different time frames the user use like 30 days, 60 days, 90 days, 6 month and 1 year. I am getting different information from the coworkers here with much more Universe knowledge that range from it can't be done to it can but not sure how.

What I would like to do is have 1 prompt called DATE and the user selects which Date object they want to use (Scheduled Date, Admitted Date Reviewed Date...etc.) then once that is selected they choose the time frame they want to user (30,60,90...etc.) This way I do not have to have dozens of filter prompts. Any idea if this can be done and how?
 
This is possible, but it gets VERY complicated...

You would have to do something similar to this (using the syntax for your database...) with nested case statements
Code:
Case @Prompt("Select Date Field".....)
  when "Start Date" then
    Case @Prompt{"Time Frame".....)
      when "30" then 
        @Select("MyClass/Start Date") between trunc(sysdate - 30) and trunc(sysdate)
      when "60" then
        @Select("MyClass/Start Date") between trunc(sysdate - 60) and trunc(sysdate)
      when <etc...>
    end
  When "Schedule Date" then
    Case @Prompt{"Time Frame".....)
      when "30" then 
        @Select("MyClass/Schedule Date") between trunc(sysdate - 30) and trunc(sysdate)
      when "60" then
        @Select("MyClass/Schedule Date") between trunc(sysdate - 60) and trunc(sysdate)
      when <etc...>
    end
  when <etc...>
end

-Dell

DecisionFirst Technologies - Six-time SAP BusinessObjects Solution Partner of the Year
[URL unfurl="true"]www.decisionfirst.com[/URL]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top