Implicit date format conversion of report column

Hello,
The following expression defines date format for report column implicitly and doesn't reflect FSP_LANGUAGE_PREFERENCE with language independent format mask of the column attribute anymore:
decode(end_date, to_date('31.12.2047', 'dd.mm.yyyy'), null, end_date) closed
end_date is of TIMESTAMP(0) WITH LOCAL TIME ZONE type, format mask of the column attribute: DS TS
Is it expected behavior?
Thanks

Edward Shevtsov wrote:
Hello,
The following expression defines date format for report column implicitly and doesn't reflect FSP_LANGUAGE_PREFERENCE with language independent format mask of the column attribute anymore:
decode(end_date, to_date('31.12.2047', 'dd.mm.yyyy'), null, end_date) closed
end_date is of TIMESTAMP(0) WITH LOCAL TIME ZONE type, format mask of the column attribute: DS TS
Is it expected behavior?
ThanksThe reason might be that you compare different datatypes in the SQL statement. The output of decode depends on those parameters.
You can cast the column to a specific datatype or you make sure that your wanted datatype is used during the decode.
example
decode(end_date, to_timestamp_tz('31.12.2047', 'dd.mm.yyyy'), null, end_date) closed
or
cast(decode(end_date, to_date('31.12.2047', 'dd.mm.yyyy'), null, end_date) as timestamp(0) with local time zone) closed

Similar Messages

  • Date Format Display on report

    Is there a way to set a custom date format on a report column? I am trying to use a format mask and it doesn't appear to be working. Maybe someone can spot my mistake:
    Query: Hours Worked = Clock_IN - Clock_OUT
    Format mask for Clock In/Clock Out - DD-MON-YYYY HH24:MI (from list)
    Format mask for Hours Worked column: HH:MI (hand typed)
    actual display (Timecard ID is edit link):
    Timecard     Employee     Vehicle     Clock IN     Clock OUT     Hours Worked
    6     20044     26045     30-JUN-2006 13:28     30-JUN-2006 13:31     +000000000 00:03:43.000000
    28     20044     144     06-JUL-2006 10:11     06-JUL-2006 10:39     +000000000 00:28:43.000000
    48     20044     144     07-JUL-2006 09:03     07-JUL-2006 16:30     +000000000 07:27:50.000000
    108     20044     26045     18-JUL-2006 15:35          
    128     20044     144     19-JUL-2006 14:57     19-JUL-2006 15:02     +000000000 00:05:06.000000

    These programs also..
    GFW_PROG_BAR : Bar chart example
    GFW_PROG_PIE: Pie chart example

  • Application Date Format in Interactive Reports

    Hi,
    What should we define in Number/Date Format in interactive reports column attributes such that it will use application level date format?
    Thanks

    Hi,
    You do not need define anything , then it use application date format
    Br,Jari

  • Date format conversation in OBIEE

    Hello guys
    I am a quick question about how to stop OBIEE from using to_date conversation? The date format in the db is dd/month/yy, and when I run any report in OBIEE answer using Date columns, it will always convert the format to "dd/mm/YYYY". The sql generated will always have a to_date() in where clause..
    Is there a way to not have OBIEE does that and just show the date with format as it is and drop the to_date conversion in SQL?
    Thanks

    I think you are getting confused here. Oracle's default date format is dd-mon-yyyy. So when you run a query like this:
    DATE_COLUMN = '01-Nov-2009'
    Oracle applies an IMPLICIT data type conversion to your date string and converts it to a date data type. Whether you allow Oracle to do the implicit conversion or do it explicitly like this DATE_COLUMN = To_date('01-Nov-2009', 'dd-mon-yyyy') should always result in the same query performance. When to TO_DATE functions affect query performance? When you apply the function over the DATE_COLUMN like this:
    TO_DATE(DATE_COLUMN, 'dd-mon-yyyy') = '01-Nov-2009'
    Why? Because indexes on DATE_COLUMN WILL NOT be used unless you have defined a function level index with a index column using the function: TO_DATE(DATE_COLUMN, 'dd-mon-yyyy'). My guess is that your DATE_COLUMN is not a date but a varchar2, therefore when you pass in To_date('01-Nov-2009', 'dd-mon-yyyy') Oracle does an IMPLICIT conversion of your DATE_COLUMN to DATE data type to match the data type of your where condition hence it is taking long to execute as no indexes are used. Can you confirm what is the exact data type of the DATE_COLUMN you are using to filter on? Do you have an index defined in that column? Can you confirm exactly how is the index is defined? Have you ran statistics on the table AND the indexes as well?

  • What is data format "Hypertext Link" in column properties??

    Hi,
    What is data format "Hypertext Link" in column properties? How to use it?
    Can I use column value to navigate to other report without using "Value Interaction" in column properties.

    By changing the data format to say HTML, or Hypertext link, you can add HTML content/HTML tags within the column formula.
    You can create a column formula that would resolve into a dynamic hyperlink and pass parameters by using Go Url. Check out Chapter 11 in the Oracle® Business Intelligence Presentation Services Administration Guide
    Check out an example:
    Re: Dyanmic display of the Image Link URL
    Search the forum as well for several similar examples.

  • RE: Oracle DATE data format conversion..

    <C.M> Motta's question about dates and oracle>
    Dealing with dates and Oracle is somewhat of a nuisance. Oracle is very
    particular about how date strings are formatted, and if you get it wrong,
    you get the (unhelpful) message that C.M. Motta showed us. However, if
    you pass a DateTimeData to Oracle, Forte' does the right formatting for you.
    If you do need to format the date prior to interacting with Oracle, use the
    following format:
    dd-mmm-yy <time component>
    You can change the default format, but it is not easy.
    If you customise Express generated code that interacts with an Oracle
    database, again, make sure that you pass a DateTimeData, and not the
    .TextValue.
    Good luck!
    Richard Kirk

    Date: Wed, 06 Nov 1996 08:18:37 -0500
    To: "C. M. Motta" <[email protected]>
    From: Jim Milbery <[email protected]>
    Subject: Re: Oracle DATE data format conversion..
    Cc: [email protected]
    Cheers:
    Most likely what is happening is that you are using the default date
    format of Oracle, and you are sending a four-character year. As follows:
    SQL> insert into jimbo values ('01-dec-1997')
    2 /
    insert into jimbo values ('01-dec-1997')
    ERROR at line 1:
    ORA-01830: date format picture ends before converting entire inputstring
    >
    Oracle defaults to a format of 'dd-MON-yy'
    You can either truncate the year, or manipulate the date to match the standard
    database as follows:
    insert into jimbo values (to_Date('01-jan-1997', 'DD-MON-YYYY'))
    \jimbo
    At 09:21 AM 11/6/96 -0200, you wrote:
    Forte Users,
    First, Id like to thank all those who answered my question on
    droplist & SQL. I got just what I was looking for: its up and runnunig
    now.
    I have another question: Im trying to insert a DATE into an Oracle
    database. The source date is:
    data : DateTimeData = new;
    data.SetCurrent();
    So, when I try to insert data.Value or data.textvalue into DB, I
    get the following exception:
    ORA-01830: date format picture ends before converting entire
    input string.
    Are there any suggestions?
    Thanks for your help,
    C.M. Motta
    ====================================================================
    Jim Milbery
    Milbery Consulting Group
    132 N. West St., Allentown, PA 18102
    O: 610 - 432 - 5350 F: 610 - 432 - 5380
    E-Mail : [email protected]
    ====================================================================

  • Regarding Date Format Conversion

    Hi,
    In my project i am picking the date from the date picker which is a javascript program . Then i am displaying it on a jsp page .It is coming in mm/dd/yyyy format .I have to change it to dd/mm/yyyy format .
    I have the code for date formatting conversion .
    What my doubt is whether  the code should be written inside the jsp page or in the javascript .
    Thanks .

    Hi
    <%@page language="java" import="java.sql.*,java.util.*,java.text.*" %>
    <%SimpleDateFormat sdf= new SimpleDateFormat(dd/mm/yyyy );%>
    <% java.util.Date temp_date = sdf.parse(PassYourDateHere); %>
    use this with your jsp
    Regards
    Abhijith YS

  • Changing date format in bw report

    Hi,
    Could anybody pls Explain How can I change date format in bw report from 19-03-2008 to 19 mar 2008.Is there any setting we need to do. Else do i need to write some ABAP code to get desired format.
    Regards,
    Sarath

    Hi Sarath,
    I could have the routine enabled and its wrk for my DATS obj ...
    else pls go through the following code
    Check this example of how to get this format..
    TABLES: T247.
    DATA: V_DATE TYPE SYDATUM.
    DATA: V_STRING(20).
    V_DATE = SY-DATUM.
    SELECT SINGLE * FROM T247
    WHERE SPRAS = SY-LANGU
    AND MNR = V_DATE+4(2).
    IF SY-SUBRC = 0.
    CONCATENATE V_DATE+6(2) '-' T247-KTX '-' V_DATE(4)
    INTO V_STRING.
    WRITE: / V_STRING.
    ENDIF.
    or make use of the routine make use of the FM
    CONVERSION_EXIT_IDATE_OUTPUT
    hope it helps you out...
    regards,
    pradeep
    Assign points if useful.

  • DATE FORMAT Conversion FOR SQL Reports

    Hi,
    Am building a report and am stuck here where this piece of code that throws the following error
    The conversion of a varchar data type to a datetime data type resulted in an out-of-range value.
    My query goes some thing like this
    DECLARE @StartDate varchar(15),
    @EndDate Varchar(15)
    SELECT @StartDate = '01/08/2014',
    @EndDate = '31/08/2014'
    SELECT DISTINCT
    [Operation] = CASE WHEN p.DATE_OF_START BETWEEN @StartDate AND @EndDate THEN 'Add'
    ELSE 'Update' END
    FROM SNZ_HR_Reporting_POSMGNT as s
    LEFT OUTER JOIN PERSON as p on s.EMP_NO = p.EMP_NO
    WHERE s.CHANGE_DATE BETWEEN @StartDate AND @EndDate
    The date format in the column DATE_OF_START  is like yyyy-mm-dd 00.00.00.000 .
    My question is how to convert this format to dd/mm/yyyy format and execute the queries
    Many Thanks,
    Bhanu

    SQL Date Format:
    http://www.sql-server-helper.com/tips/date-formats.aspx
    Please Mark This As Answer if it helps to solve the issue

  • #ERROR message in report for date format conversion

    Dear Collegues,
    Why is it that I get #ERROR message (instead of date value) in my report when I use the formula
    =ToDate(UserResponse("Enter End Date:");"dd.MM.yyyy")   ??
    When I only write UserResponse("Enter End Date:") I get the appropriate date, f.ex 5/12/2009. This is american standard for 5th of may, I need to see it like 12/05/2009.
    If I try to just enter the date object behind the prompt ([Settlement Date]) i get message #MULTIVALUE even though I have promptet for 1 special date...
    Is there another formula I can use to get the right format? I can't adjust the format using properties, it doesn't make any difference, the settings I put in there.
    Regards Silje

    Thank you for the very quick answer! Using FormatDate() I get an error message while validating the formula:
    The expression or sub-expression at position 12 in the FormatDate function uses an invalid data type. (WIS 10037)
    I tried making a variable inside BO called [End Date] = userResponse("Enter End Date:") but I get the same error message then. Creating a variable you can only choose between Dimension, Measure and Detail, not Date. Is that some of the reason?
    Finally I tried FormatDate([Settlement Date]; "dd.MM.yyyy"). Validating the formula I get the message that the formula is correct, but in the report the field containes message #MULTIVALUE...
    SILJE

  • Does not appear possible to use date formatting in interactive reports

    I've an interactive report displaying a column of data type = date. When populated with the result of "select (sysdate) from dual;", regardless of what data type conversion (to_char/to_date) or what time formatting is used (attempting DD-MON-YYYY HH:MIPM), the displayed time is always 12:00AM.
    Thanks!
    Paul

    Can you post a small example of what you are trying to do on the hosted instance of APEX from Oracle? You are trying to get the following:
    SELECT TO_CHAR(SYSDATE,'DD-MON-YYYY HH:MI PM') test_col FROM DUAL to format properly?
    It returns: 18-NOV-2010 09:51 PM in a one column report for me..
    Thank you,
    Tony Miller
    Webster, TX
    You can get more with a kind word and a two-by-four than you can with just a kind word
    Anla-shok Marcus from Babylon 5

  • Date format in obiee reports

    HI guys
    i got two obiee server running in our env . both are identical . on one server when ever we rite any report with date column in it it comes up with dd/mm/yyyy output on another server if we right any report all the date column comes with dd mon yyyy format .. i want both of them should show date like dd mon yyyy format .. i checked all the conf files are both are looking same still not able to figure out where should i change for this to work .
    please let me know if you need more info from my end.
    Regards,
    Dev

    HI Kishore
    Thanks for your reply i checked all the things but with no success. do think there could be any other place where i should check .
    1. nqsconfig date format
    its same for both the two installations
    DATE_TIME_DISPLAY_FORMAT = "yyyy/mm/dd hh:mi:ss" ;
    DATE_DISPLAY_FORMAT = "yyyy/mm/dd" ;
    TIME_DISPLAY_FORMAT = "hh:mi:ss" ;
    2. make sure that you didn't save date format in column properties from front-end
    Just checked and we havan't saved anything in column properties .. even i created new report as well but still format was same ..
    3. Did you mention anything in connection pool settings to set date format.
    no we havan't mention anything in connection pool
    4. Make sure that you are connecting to same database, and date format set for date is same here and there
    yahh both the two installatiosn are connected to same database .. but not sure about "date format set for date is same here and there
    " hw i can check this
    finally, check this: http://108obiee.blogspot.com/2009/04/changing-date-format-mask-in-javascript.html
    no its not on one column .. its to all the date format columns on all the reports .. so i think its not case with me .
    please let me know if you need more info
    Regards,
    Dev

  • Date format in Discovere Reports

    We have created a workbook with a parameter which is supposed to show up an LOV for a parameter in the MON-RR format. Now this LOV shows up
    correctly in the Discoverer Desktop edition as MON-RR format, but when we view
    the same in Discoverer Viewer it shows up as DD-MON-RRRR.
    Earlier we had got a partial resolution on this issue (TAR 3891425.996), wherein by changing the ICX
    profile value in Oracle Applications, we are able to set the date mask to MON-R
    R.
    But now the above profile applies to all the reports and all the dates show up as MON-RR, whereas we want to continue showing the date in DD-MON-RRRR forma
    t in some of the reports.
    How can this be achieved ?

    HI Kishore
    Thanks for your reply i checked all the things but with no success. do think there could be any other place where i should check .
    1. nqsconfig date format
    its same for both the two installations
    DATE_TIME_DISPLAY_FORMAT = "yyyy/mm/dd hh:mi:ss" ;
    DATE_DISPLAY_FORMAT = "yyyy/mm/dd" ;
    TIME_DISPLAY_FORMAT = "hh:mi:ss" ;
    2. make sure that you didn't save date format in column properties from front-end
    Just checked and we havan't saved anything in column properties .. even i created new report as well but still format was same ..
    3. Did you mention anything in connection pool settings to set date format.
    no we havan't mention anything in connection pool
    4. Make sure that you are connecting to same database, and date format set for date is same here and there
    yahh both the two installatiosn are connected to same database .. but not sure about "date format set for date is same here and there
    " hw i can check this
    finally, check this: http://108obiee.blogspot.com/2009/04/changing-date-format-mask-in-javascript.html
    no its not on one column .. its to all the date format columns on all the reports .. so i think its not case with me .
    please let me know if you need more info
    Regards,
    Dev

  • Date Format in Portal Report

    Hi,
    I have created a SQL Report with following select statement. Looks like portal has default format mask for date type as 'DD-MM-YY'.
    If I put DD-MM-YYYY or DD-MM-RRRR in Format Mask field in Column Formatting screen, the reports generates 04-10-0002 . It should
    be 04-10-2002.
    select process_id, last_update_date
    from obm
    where process_id like (:process_id)
    I tried to use the to_char function as following. But it errors ORA-06502:PL/SQL:numeric or value error. Even though it works fine in
    my sqlplus session.
    select process_id, to_char(last_update_date, 'DD-MM-YYYY')
    from obm
    where process_id like (:process_id)
    Does anyone have any idea?
    Thanks

    Hi,
    Which version of portal are you using? The error with to_char comes in 30984. This is a bug. The bug no is 2567445. A one-off has been issued. Please look in metalink for it. And for the date formatting in the column formatting section the formatting should work fine. Please check the data in your table.
    Thanks,
    Sharmila

  • Date formatting on updateable report

    I have an updateable report with a date column. I would like the user to be able to use mm/dd/rrrr format.
    Is this possible?
    Thanks

    when you use our tabular form wizard to generate a tabular form, you're somewhat limited in what you can do to the data that's being selected out of your table. it's currently set up that way because we do some optimistic locking stuff behind the scenes to maintain your data integrity for you. there might be other ways to deal with your specific request, but this approach seems easiest to me assuming that changing your db's default date format isn't an option:
    put html db pl/sql processes on both your page rendering and page submission sections that set your nls_date_format for each of those db sessions. so both of your new html db processes would be of type "PL/SQL Anonymous Block". one would fire with a process point of "On Load - Before Header" and the other would fire "On Submit - Before Computations and Validations". both processes would look like...
    begin
    execute immediate 'alter session set nls_date_format = ''mm/dd/rrrr''';
    end;
    ...and after those two changes, your tablular form should handle dates in the mm/dd/rrrr format you're looking for.
    hope this helps,
    raj

Maybe you are looking for