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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Condtional (If...Then...Else) Object in a Universe

Status
Not open for further replies.

MJRBIM

MIS
May 30, 2003
1,579
CA
Can you create a condtional (If...Then...Else) Object in the Universe to allow for PROMPTING...?

I have a condtional (If...Then...Else) field that I created as a variable in a DeskI report which is fine for display purposes - but now I want to be able to use that same condition as a PROMPT on the Query.

If I can't create the condtional (If...Then...Else) Object in the Universe, am I stuck with having to create it as a new field on the underlying Oracle view then pulling that orcale field into the Universe...?

Thanks in advance!
 
When working with universes you're dealing directly with the native SQL of the database. If..then..else constructs are not directly supported.
All major RDBMS support the CASE construct which has the same effect. (Oracle did have it's own solution using DECODE).
In general:

Code:
CASE 
WHEN
<<condition1>>
THEN <<expression1>>
WHEN
<<condition2>>
THEN <<expression2>>
WHEN
<<condition3>>
THEN <<expression3>>
...
...
...
ELSE <<other option>>
END



Ties Blom

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top