Home » Developer & Programmer » Reports & Discoverer » Conditional dropdown list in parameter form (Report Builder 9.0.4.1.0, Windows XP Professional)
Conditional dropdown list in parameter form [message #383677] Thu, 29 January 2009 11:40 Go to next message
scorpio4frenz
Messages: 48
Registered: October 2008
Member
I have a report with a parameter form containing a parameter called "person_name". As of now, it is a dropdown list which is built using a select query over my "people" table and displays all the people in the table. I need to add a checkbox on the parameter page which says "Show only current people" and when this checkbox is checked, the "person_name" dropdown list should be limited to only current people. I don't know how to add a checkbox to the parameter form, and how to implement this conditional if-then-else on the dropdown list.

My current query for the dropdown list is:
SELECT 1 co11,' ALL - ALL' col2
FROM dual
UNION
SELECT person_seq_num col1, last_name||','||first_name col2
FROM people
ORDER BY 2 asc


When the checkbox is checked, my query needs to be:
SELECT 1 co11,' ALL - ALL' col2
FROM dual
UNION
SELECT person_seq_num col1, last_name||','||first_name col2
FROM people
WHERE person_current_flag='Y'
ORDER BY 2 asc


Can anyone help with this problem? Thanks in advance.
Re: Conditional dropdown list in parameter form [message #383695 is a reply to message #383677] Thu, 29 January 2009 14:35 Go to previous messageGo to next message
Littlefoot
Messages: 21823
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Not possible (as far as I can tell).

Allegedly possible with some help of Java code; however, I have never seen actual proof as a person who said he did it never replied in order to share the solution.
Re: Conditional dropdown list in parameter form [message #383698 is a reply to message #383695] Thu, 29 January 2009 14:43 Go to previous messageGo to next message
scorpio4frenz
Messages: 48
Registered: October 2008
Member
That's what i thought..i've never seen such an implementation before. I just wanted to be sure.

Any suggestions for a work around? Achieving this functionality would be good. I can't think of an alternative except creating a separate dropdown list!
Re: Conditional dropdown list in parameter form [message #383701 is a reply to message #383698] Thu, 29 January 2009 15:02 Go to previous message
Littlefoot
Messages: 21823
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I've already mentioned a possible workaround in a reply to the "Not possible" linked topic (create your own parameter form using Forms Builder).
Previous Topic: Hot to access global variables of forms?
Next Topic: Oracle Reports
Goto Forum:
  


Current Time: Sat Nov 30 05:17:01 CST 2024