Oracle Analytics Cloud and Server

Welcome to the Oracle Analytics Community: Please complete your User Profile and upload your Profile Picture

How to use ELSEIF condition in obiee?

Received Response
21
Views
22
Comments
2

Answers

  • cesar.advincula.o
    cesar.advincula.o Rank 6 - Analytics Lead

    Hello,

    I could see that you have a lowe case in your format yyyy , dd , do you try with UPPER CASE YYYY DD.

    I dont have any problem.


    dt3.png


    Kind Regards,

  • User_N86UL
    User_N86UL Rank 3 - Community Apprentice

    Still getting the same error.

    Please help as I need it urgently.

  • User_N86UL
    User_N86UL Rank 3 - Community Apprentice

    Date.jpg

    This is the value in UDF 01.

  • Sorry but if you posted that your date is in the format "yyyy-mm-dd" why are you trying to use a "mm/dd/yyyy" format?

    Cesar did 2 examples, one as the format of date you posted (yyyy-mm-dd) and it works fine.

    So what does your date really look like? Maybe double check that part as you aren't really sure (I don't think you changed the date format for your UDF values in the source in the last 15 minutes ...)

    PS: I guess we are really trying our best to help you, so asking for something "urgently" ... well ... hire a consultant if an answer every 5 minutes isn't "urgent" enough ... (keep in mind it's a community forum )

  • cesar.advincula.o
    cesar.advincula.o Rank 6 - Analytics Lead

    Hello,

    I dont have any the problem i try with the format that you want, the only reason that you have problem its your "Candidate UDFs"."Candidate UDF Value 01" column have

    a value that doesnt have the format( 'MM/DD/YYYY').

    DTT.png

    DTT2.png

    Kind Regards,

  • User_N86UL
    User_N86UL Rank 3 - Community Apprentice

    Date1.jpg

    After trying this

    TO_DATETIME("Candidate UDFs"."Candidate UDF Value 01",'YYYY-MM-DD')

    and

    TO_DATETIME("Candidate UDFs"."Candidate UDF Value 01",'yyyy-MM-dd')

    Still getting the error :

    Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P

    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OBIS. [nQSError: 17001] Oracle Error code: 1841, message: ORA-01841: (full) year must be between -4713 and +9999, and not be 0 at OCI call OCIStmtFetch. [nQSError: 17012] Bulk fetch failed. (HY000)

  • Well, the error is different at least, already a good step

    All your rows have a value for Candidate UDF Value 01 ? All the values are a valid date ? Don't you have Nulls values there somewhere ?

    If one is NULL you must manage it.

  • cesar.advincula.o
    cesar.advincula.o Rank 6 - Analytics Lead

    Hello,

    Are you sure that all the values that you have in your column have this format? check what the ORA-01841 says, you have to get -4713 and +9999 and not to be 0 at OCI,

    I believe one of all your values in your column doesnt comply the format, for that reason, you get the error.

  • User_N86UL
    User_N86UL Rank 3 - Community Apprentice

    I have checked it, it also contain NULL value.

    how to overcome with this problem?

  • cesar.advincula.o
    cesar.advincula.o Rank 6 - Analytics Lead

    Hello,

    1.Use IFNULL function in your colum something like this: TO_DATETIME( IFNULL("UDF COLUMN",'2000-01-01'),'YYYY-MM-DD').

    Note: Check, '2000-01-01' is a sample value that i give you, you can put whatever value that you want, obviously, with the format of the date (YYYY-MM-DD).

    2. Or make a FILTER in your CRITERIA section, to your column ( UDF Column)  "is not null"