Categories
- All Categories
- Oracle Analytics and AI Learning Hub
- 44 Oracle Analytics and AI Sharing Center
- 20 Oracle Analytics and AI Lounge
- 278 Oracle Analytics and AI News
- 56 Oracle Analytics and AI Videos
- 16.2K Oracle Analytics and AI Forums
- 6.4K Oracle Analytics and AI Labs
- Oracle Analytics and AI User Groups
- 103 Oracle Analytics and AI Trainings
- 20 Oracle Analytics and AI Challenge
- Find Partners
- For Partners
Case When for date fields
Summary
Case when date is lesser than or equal to another date, THEN "on time", ELSE, "Not on time"
Content
I'm trying to build a Case statement that shows If one date is lesser than or equal to another, say "on time", else, say "not on time" (or some other decided upon phrase). Is that possible to do in OBIEE? Or can I only do Case statements when the the "Then" and the "Else" are other columns? Any thoughts on how to trick the column to do what I want it to do?
Answers
-
Hi Stephanie
Yes this is possible! You would put the hard-coded value inside single quotation/apostrophe marks.
For instance:
CASE WHEN DATE1 <= DATE2 THEN 'On Time' ELSE 'Not on Time' END
Kind Regards
Aaron
0 -
Yes! That was all that I needed. I had the statement written but was using double quotes. Thanks!
0