Problem with date format when ask prompt web-intelligence

Bo XIR2 with 5 SP. Instaled on Windows 2003 with support Russian.
Inside BO every labels, buttons - use russian. But when invoke web-report and Prompt appear there is problem with date format.
Looks like korean format of date 'jj.nn.aaa H:mm:ss'.  I see system settings of date in Win .. everything right
What i have to do?
Where i can change format date for bo?

GK, try this...
decode(instr(packagename.functionname(param1 ,param2),'2400'), 0, to_date(to_char(to_date(rtrim(packagename.functionname(param1 ,param2),'(PT)'), 'Month dd, yyyy "at" hh24mi'),'mm/dd/yyyy hh24mi'),'mm/dd/yyyy hh24mi'),
                                                                  to_date(to_char(to_date(rtrim(packagename.functionname(param1 ,param2),'(PT)'), 'Month dd, yyyy "at" "2400"')+1,'mm/dd/yyyy "0000"'),'mm/dd/yyyy "0000"'))-Marilyn

Similar Messages

  • Problem with data format when getting from a database

    I'm trying to get a date from the database but the problem is that it also return the time. I have tried to change the format of the date when retrived from my database but it still returns the time.
    Any solutions?
    String theDBDate = rset.getString("date_of_call");
    SimpleDateFormat formatterdate = new SimpleDateFormat ("EEE, MMM d, ''yy");
    String date = formatterdate.format(theDBDate);
    theCalls.setDateofCall(date);// callin my Call Class to store the date which is a string

    Hi could any help me? I have this problem for the last few day. I gave up on it for a while but today I'm trying to get to the botton of this problem.
    I connecting to an oracle database but it return back the date & time but I want only the date.
    Here my code.
    Locale currentLocale= new Locale("en","GB");
    Date today = new Date();
    DateFormat formatter = DateFormat.getDateInstance(DateFormat.DATE_FIELD,currentLocale);
    String theSQL = (" Select * From Call ") ;
    Statement stmt;
    stmt = conn.createStatement();
    ArrayList CallsList = new ArrayList();
    ResultSet rset;
    rset = stmt.executeQuery(theSQL);
    while(rset.next() == true)
    Call theCalls = new Call();
    theCalls.setCallNo(rset.getInt("call_no"));
    theCalls.setUsername(rset.getString("username"));
    theCalls.setCompID(rset.getString("comp_id"));
    theCalls.setTimeofCall(rset.getString("time_of_call"));
    Date todaydate = rset.getDate("date_of_call");
    Timestamp theDBDate = rset.getTimestamp("date_of_call");
    SimpleDateFormat formatterdate = new SimpleDateFormat ("EEE, MMM d, ''yy");
    String date = formatterdate.format(theDBDate);
    theCalls.setDateofCall(date);
    theCalls.setPriorty(rset.getString("priorty"));
    theCalls.setProbCat(rset.getString("problem_cat"));
    theCalls.setProbDesc(rset.getString("problem_desc"));
    theCalls.setCloseDate(rset.getString("close_date"));
    theCalls.setProbSol(rset.getString("problem_sol"));
    theCalls.setStatus(rset.getString("status"));
    theCalls.setAssign(rset.getString("assign"));
    CallsList.add(theCalls);
    conn.close();
    return CallsList;

  • Problem with Date format

    Got one more problem Merilyn and Radhakrishnan...
    Regarding the soln y provided me earler with the thread "Problem with date format"...
    What is happening is....I am able to change the 2400 to 0000 but when it is changed from 2400 on jan 1st to 0000 the hour is changing but not the date....the date still remains as jan 1st instead of jan 2nd....
    Eg: Jan 1st 2400 -- changed to -- jan1st 0000
    instead of jan 2nd 0000
    Could you please help me in this issue...
    Thanks,
    GK

    GK, try this...
    decode(instr(packagename.functionname(param1 ,param2),'2400'), 0, to_date(to_char(to_date(rtrim(packagename.functionname(param1 ,param2),'(PT)'), 'Month dd, yyyy "at" hh24mi'),'mm/dd/yyyy hh24mi'),'mm/dd/yyyy hh24mi'),
                                                                      to_date(to_char(to_date(rtrim(packagename.functionname(param1 ,param2),'(PT)'), 'Month dd, yyyy "at" "2400"')+1,'mm/dd/yyyy "0000"'),'mm/dd/yyyy "0000"'))-Marilyn

  • Problem with date format dd/mm/yyyy. But I need to convert yyyy-mm-dd.

    Dear friends,
    I have the problem with date format. I receiving the date with the format dd/mm/yyyy. But I can upload to MySQL only in the format of yyyy-mm-dd.
    how should I handle this situation, for this I've created these code lines.But I have some problem with these line. please help me to solve this problem.
    String pattern = "yyyy-mm-dd";
    SimpleDateFormat format = new SimpleDateFormat(pattern);
    try {
    Date date = format.parse("2006-02-12");
    System.out.println(date);
    } catch (ParseException e) {
    e.printStackTrace();
    System.out.println(format.format(new Date()));
    this out put gives me Tue Apr 03 00:00:00 IST 2007
    But I need the date format in yyyy-mm-dd.
    regards,
    maza
    thanks in advance.

    Thanks Dear BalusC,
    I tried with this,
    rs.getString("DATA_SCAD1")// where the source from .xls files
    String pattern = "yyyy-MM-dd";
    SimpleDateFormat format = new SimpleDateFormat(pattern);
    try {
    Date date = format.parse("DATA_SCAD1");
    System.out.println(date);
    } catch (ParseException e) {
    e.printStackTrace();
    System.out.println(format.format(new Date()));
    this out put gives me Tue Apr 03 00:00:00 IST 2007
    But I want to display the date format in yyyy-mm-dd.
    regards,
    maza

  • Problem with date format from Oracle DB

    Hi,
    I am facing a problem with date fields from Oracle DB sources. The date format of the field in DB table is 'Date base type is DATE and DDIC type is DATS'.
    I mapped the date fields to Date characters in BI. Now the data that comes to PSA is in weird format. It shows like -0.PR.09-A
    I have changing the field settings in DataSource  to internal and external and also i have tried mapping these date fields to text fields with out luck. All delivers the same format.
    I have also tried using conversion routines like, CONVERSION_EXIT_IDATE_INPUT to change format. It also delivers me the same old result.
    If anybody of you have any suggestions or if anybody have you experienced such probelms, Please share your experience with me.
    Thanks in advance.
    Regards
    Varada

    Thanks for all your reply. I can only the solutions creating view in database. I want some solution to be done in BI. I appreciate if some of you have idea in it.
    The issue again in detail
    I am facing an issue with date fields from oracle data. The data that is sent from Oracle is in the format is -0.AR.04-M. I am able to convert this date in BI with conversion routine in BI into format 04-MAR-0.
    The problem is,  I am getting data of length 10 (Output format) in the format -0.AR.04-M where the month is not in numericals. Since it is in text it is taking one character spacing more.
    I have tried in different ways to convert and increased the length in BI, the result is same. I am wondering if we can change the date format in database.
    I am in puzzle with the this date format. I have checked other Oracle DB connections data for date fields in BI, they get data in the format 20.081.031 which will allow to convert this in BI. Only from the system i am trying creating a problem.
    Regards
    Varada

  • Problem with date format parameter in SSRS2012 after migration from SSRS2008

    Hello,
    We are migration from
    Reporting Services 2008 on Windows 2008 server
    to
    Reporting Services 2012 with Always On on Windows 2012 server.
    I have a report that expects a date in the querystring: "...&DateTo=17/09/2014"
    This use to work in the previous environment and now fails !
    I logged onto the server with the credentials that runs SSRS and changed its regional settings to French(France): It didn't helped.
    I tried passing in the date otherwise "...&DateTo=09/17/2014": it worked !
    I tried changing the regional settings in my IE and it worked but that can't be a solution... it is still working on my Windows 2008 server... unless there is a statement from Microsoft that it explains that now it works only like this but I would be surprised... is it ?
    I also saw that changing a directive in the web page can help but, why did it stopped working, is it the handling of a default value for regional settings that changed in SSRS ?
    I would need help to understand this, thank you for any help you can provide.
    Regards,
    Claude VERNIER
    

    Hi Claude,
    Based on my research, SQL Server doesn’t supports DD/MM/YYYY date format. When we insert “17/09/2014” value in a date type column, it pops up an error message that “String was not recognized as a valid DateTime”. It means that the value “17/09/2014” is acted
    as “2014/17/09” string. So in your scenario, we cannot get the expect results.
    To work around this issue, we should change it to “09/17/2014”.
    Reference:
    Date and Time Data Types and Functions (Transact-SQL)
    If there are any other questions, please feel free to ask.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • HS Services vs Excel. Problem with data format.

    Hi,
    I'm facing a problem after trying to use HS Services to connect an Excel Sheet with Oracle 10G.
    I got several columns and I expect all of them to be varchar2 type, whereas Oracle is showing a table using float types in some of them. I am trying to find any difference in excel sheet but haven't seen one yet.
    So, this is a brief example of what I am facing in the excel sheet:
    Excel Col A B C D E F G H
    Data FAMIY     COMMON NAME     SCIENTIFIC NAME     CATEGORY      L     F     C     T
    Data ANATIDAE     Barnacla carinegra Branta bernicla     I     0     0     0     0
    Data Tarro blanco     Tadorna tadorna     I     0     1/N     1     1
    So, i'm getting columns from E to H like Float(49) in Oracle. They DO contain a 90% of numbers, but it's possible to find some literals like '1/N' or '0/N'.
    Any clue?
    Thanks in advance and ask for any extra information if needed.

    HI BluShadow. First of all thank you for the answer.
    I've been working on this today and I have reached the solution.
    [http://support.microsoft.com/kb/141284/en-us] you can check about the problems that ODBC causes when reading mixed data types in excel.
    So solution is, in this case, re-creating (not copying) a new sheet and after making sure all cells have been selected as Text number format, allocate data inside.
    In my case, i have decided to make a macro for the process.
    Edited by: JSaenz on 14-nov-2011 7:07

  • Problem With Date Format Mask

    Hi everyone,
    when i set the date format mask in any field..
    if i enter any wrong date format messages are coming in to loop
    is this is bug of format mask?
    how can i avoid this..
    thanks in advance
    anand mohan

    It should not take you into a loop. If the "validation" against the format mask fails, a message is displayed, and the focus is returned to the field which caused the problem. Do you maybe have some method or event associated with the field which could be causing the circular behavior?
    -- Brian

  • Problem with Date formatting

    Hi Tim,
    I am facing some issues with formatting the date using XMLP. The following is the sample XML data file i am using:
    <LIST_G_HEADER>
    <G_HEADER>
    <QUOTE_HEADER_ID>1455</QUOTE_HEADER_ID>
    <QUOTE_NUMBER>2027</QUOTE_NUMBER>
    <QUOTE_VERSION>1</QUOTE_VERSION>
    <QUOTE_NAME>Test GM Report - Rabindra</QUOTE_NAME>
    <SOURCE_NAME>Fletcher, MR. Paul</SOURCE_NAME>
    <QUOTE_DATE>27-OCT-2005</QUOTE_DATE>
    <CURRENCY_CODE>GBP</CURRENCY_CODE>
    </G_HEADER>
    </LIST_G_HEADER>
    The formatting i use for my date field i.e <QUOTE_DATE>, ends up either with NO formatting or giving me an error "[010906_114656657][][ERROR] Invalid XSD string: 27-OCT-2005 (XMLP Template Viewer)". The default formatting available with the form field dialog box (MS-Word) feature also doesn't work.
    I have the following formatting for this field in the form field:
    <?format-date:QUOTE_DATE; 'MEDIUM' ?>
    When i read the user guide, it reads that the date should be in the canonical format i.e: YYY-MM-DDThh:mm:ss+HH:MM
    However i am not getting the date from the base table's in this format. Is the error happening due to incorrect format or is there some other reason behind this? Please let me know, how can i overcome this issue.
    Thx,
    Nitin

    As i mentioned in another thread
    substring function and date format
    Please use this standards
    <?xdofx:expression?>
    for extended SQL functions or
    <?xdoxslt:expression?>
    for extended XSL functions.
    Use like
    <?xdofx:rpad(LAST_NAME),30, ’x’)?>
    <?xdofx:Instr(’abcabcabc’,’a’,2))?>
    <?xdofx:upper(char)?>
    <?xdofx:lower (char)?>
    <?xdofx:greatest ( expr [, expr]... )?>
    ETC.....

  • Problem with date format mask 'D'

    I am experiencing an extremely thorny problem with the date format mask ‘D’. I am trying to use it to check whether today is a Monday. The variable v_temp_day is set to sysdate. For the last 4 weeks the code has behaved erratically – giving a different result at 02:00 than at 10:30 even though it is only taking account of the date. In desperation I inserted a debug statement formatting the date in a variety of ways – with interesting results. Oracle is somehow managing to tell us that today is simultaneously Monday and Tuesday depending on which format mask you choose. Anyone got any thoughts or suggestions?
    PROC_ID TO_CHAR(STAMP_TIM
    EVENT_SQLERRM
    RRHKP010 17092007 02:00:00
    TO_NUMBER( TO_CHAR( v_temp_day, D ) ) = 2. TO_CHAR( v_temp_day, D ) = 2. TO_CHAR( v_temp_day, DY ) = MON. TO_CHAR( v_temp_day, DAY )
    = MONDAY . TO_CHAR( v_temp_day, Day DD-MON-YYYY HH24MISS ) = Monday 17-SEP-2007 020000. TO_CHAR( v_temp_day, D ) = 2.
    SQL> select to_char( sysdate, 'D' ) from dual ;
    T
    1

    My book says the trunc(d,'iw') will return "same day of the week as Jan 1st of that year"It's bad book.
    Please read about [url http://oraclesvca2.oracle.com/docs/cd/B10501_01/server.920/a96540/functions176a.htm#80159]TRUNC & 'IW' Format Model and [url http://oraclesvca2.oracle.com/docs/cd/B10501_01/server.920/a96529/ch3.htm#50331]Database Globalization Support Guide: First Calendar Week of the Year in the manual.

  • Problems With Data Alignment when spooling to a CSV file

    Dear members,
    I am spooling data to a csv file. My data contains 3 columns
    For example :
    col1 col2 col3
    USD,10000033020000000000000,-1144206.34
    The 2nd column is alphanumeric, it contains some rows which have only numbers and some which have numbers and alphabets.
    The 3rd column contains only numbers with positive or negative values.
    I am facing problem with alignment. when i open the spooled csv file then i find that the 3rd column is aligned to right .
    In the 2nd column, rows which have only numbers are right justified and rows which have alpha numeric data are left justified.
    I tried using the JUSTIFY function in sql plus but still it is not working for me.
    Can any body give your opinion on how to control the alignment in spooled csv files.
    Your responce is highly appreciated.
    Here is my code :
    WHENEVER SQLERROR CONTINUE
    SET TIMING off
    set feedback off
    set heading off
    set termout OFF
    set pagesize 0
    set linesize 200
    set verify off
    set trimspool ON
    SET NEWPAGE NONE
    col to_char(glcd.segment1||glcd.segment2||glcd.segment3||glcd.segment4||glcd.segment5||glcd.segment6) ALIAS CONCATENATED_SEGMENTS
    col CONCATENATED_SEGMENTS justify left
    col to_char(decode(glbal.currency_code,glsob.currency_code,
    (begin_balance_dr - begin_balance_cr) + (period_net_dr -period_net_cr),
    (begin_balance_dr_beq - begin_balance_cr_beq) + (period_net_dr_beq -period_net_cr_beq))) alias Total_Functional_Currency
    col Total_Functional_Currency justify left
    COlUMN V_INSTANCE NEW_VALUE V_inst noprint
    select trim(lower(instance_name)) V_INSTANCE
    from v$instance;
    column clogname new_value logname
    select '/d01/oracle/'|| '&&V_inst' ||'out/outbound/KEMET_BALANCE_FILE_EXTRACT' clogname from dual;
    spool &&logname..csv
    SELECT glsob.currency_code ||','||
    to_char(glcd.segment1||glcd.segment2||glcd.segment3||glcd.segment4||glcd.segment5||glcd.segment6) ||','||
    to_char(decode(glbal.currency_code,glsob.currency_code,
    (begin_balance_dr - begin_balance_cr) + (period_net_dr -period_net_cr),
    (begin_balance_dr_beq - begin_balance_cr_beq) + (period_net_dr_beq -period_net_cr_beq)))
    from gl_balances glbal , gl_code_combinations glcd , gl_sets_of_books glsob
    where      period_name = '&1' /* Period Name */
    and      glbal.translated_flag IS NULL
    and      glbal.code_combination_id = glcd.code_combination_id
    and      glbal.set_of_books_id = glsob.set_of_books_id
    and      glbal.actual_flag = 'A'
    and      glsob.short_name in ('KEC-BOOKS' , 'KUE' , 'KEU','KEMS', 'KEAL' , 'KEAL-TW' , 'KEAL-SZ' , 'KEAM')
    and glcd.segment1 != '05'
    and decode(glbal.currency_code , glsob.currency_code , (begin_balance_dr - begin_balance_cr) + (period_net_dr -period_net_cr) ,
    (begin_balance_dr_beq - begin_balance_cr_beq) + (period_net_dr_beq -period_net_cr_beq)) != 0
    and glbal.template_id IS NULL
    ORDER BY glcd.segment1 || glcd.segment2 || glcd.segment3 || glcd.segment4 || glcd.segment5 || glcd.segment6
    spool off
    SET TIMING on
    set termout on
    set feedback on
    set heading on
    set pagesize 35
    set linesize 100
    set echo on
    set verify on
    Thanks
    Sandeep

    i think you do not have to worry about your code when you say that the plain texts created are ok when opened on the notepad. it is on the excel that you will need some adjustments. not sure about this but you might want to read about the applying styles in the excel by going through it's help menu.

  • URGENT !!!!   Problem with Date format MM/DD/YYYY in oracle database to BW

    Hi
    I am wondering if somebody can help me urgently.
    I have oracle database where date is of the format MM/DD/YYYY and I am loading data into BW. DATE data type
    Date in oracle database: 3/30/2007
    First when I used InfoObject ZDATE (with 0DATE) reference (DATS data type) data load failed saying that
    'Value '30-MAR-0 ' of characteristic 0DATE is not a number with 000008 spaces'
    Then I created ZDATE InfoObject as CHAR Type (Length 10) with PDATE Conversion Routine.
    when I created datasource using DB Connect and checked the contents using 'Display Table Contents' after creating data source the data field distorted as
    AR/-0/30-M
    After data load. when I checked PSA
    The Date records look same as AR/-0/30-M
    In cube the field appeared as  30-MAR-0  (last digit of year disappearing)
    In BEx report also it looks like 'AR/-0/30-M'
    Can somebody help me as quickly as possible.
    What should I do if i want to still use DATS data type for ZDATE?
    should I change date format in database if so to what?
    If I should use CHAR type with PDATE or any other routine can somebody give me the routine to have the date in the report exactly as it appears in database?
    I also tried changing date format in user profile...settings. But still its the same.
    Thanks in advance.

    Hello Snrella,
    You can solve this by converting the date format from oracle to the SAP internal date format  using an ABAP routine in the transfer rules.
    Assuming the oracle data field name is ZODATE then here's the ABAP you can use in the transfer rules. Create an ABAP routine transfer rule from ZODATE to your ZDATE infoobject, and then put this ABAP code there. (this code assumes that the format of the date from oracle is MM/DD/YYYY).
    concatenate tran_structure-/BIC/ZODATE+6(4) tran_structure-/BIC/ZODATE(2) tran_structure-/BIC/ZODATE+3(2) into result.
    Hope this helps.

  • SQL Loader Problem with Date Format

    Dear all,
    I am dealing with a problem in loading data with SQL Loader. The problem is in the date format.
    More specifically, I created the following Control File:
    file.ctl
    LOAD DATA
    INFILE 'D:\gbal\chatium.log'
    APPEND INTO TABLE CHAT_SL
    FIELDS TERMINATED BY WHITESPACE
    TRAILING NULLCOLS
    (SL1 DATE "Mon DD, YYYY HH:MI:SS FF3AM",
    SL2 char,
    SL3 DATE "Mon DD, YYYY HH:MI:SS FF3AM",
    SL4 char,
    SL5 char,
    SL6 char,
    SL7 char,
    SL8 char,
    SL9 char,
    SL10 char,
    SL11 char,
    SL12 char,
    SL13 char,
    SL14 char,
    SL15 char)
    The data we want to load are in the following file:
    Apr 29, 2007 12:05:49 AM 1060615 Apr 29, 2007 12:05:35 AM 306978537730 24026384 chatium.user.userinfo WAP 0
    Apr 29, 2007 12:12:51 AM 1061251 Apr 29, 2007 12:12:27 AM 306978537730 24026384 chatium.channel.list WAP 0
    Apr 29, 2007 12:12:51 AM 1061264 Apr 29, 2007 12:12:32 AM 306978537730 24026384 chatium.channel.listdetail WAP 0
    Apr 29, 2007 12:13:51 AM 1061321 Apr 29, 2007 12:13:31 AM 306978537730 24026384 chatium.user.search WAP 0
    Apr 29, 2007 12:13:51 AM 1061330 Apr 29, 2007 12:13:37 AM 306978537730 24026384 chatium.user.userinfo WAP 0
    The error log file is the following:
    SQL*Loader: Release 9.2.0.1.0 - Production on Mon Apr 30 11:29:16 2007
    Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
    Control File: file.ctl
    Data File: D:\gbal\chatium.log
    Bad File: chatium.bad
    Discard File: none specified
    (Allow all discards)
    Number to load: ALL
    Number to skip: 0
    Errors allowed: 50
    Bind array: 64 rows, maximum of 256000 bytes
    Continuation: none specified
    Path used: Conventional
    Table CHAT_SL, loaded from every logical record.
    Insert option in effect for this table: APPEND
    TRAILING NULLCOLS option in effect
    Column Name Position Len Term Encl Datatype
    SL1 FIRST * WHT DATE MonDD,YYYYHH:MI:SS
    SL2 NEXT * WHT CHARACTER
    SL3 NEXT * WHT CHARACTER
    SL4 NEXT * WHT CHARACTER
    SL5 NEXT * WHT CHARACTER
    SL6 NEXT * WHT CHARACTER
    SL7 NEXT * WHT CHARACTER
    SL8 NEXT * WHT CHARACTER
    SL9 NEXT * WHT CHARACTER
    SL10 NEXT * WHT CHARACTER
    SL11 NEXT * WHT CHARACTER
    SL12 NEXT * WHT CHARACTER
    SL13 NEXT * WHT CHARACTER
    SL14 NEXT * WHT CHARACTER
    SL15 NEXT * WHT CHARACTER
    Record 1: Rejected - Error on table CHAT_SL, column SL1.
    ORA-01840: input value not long enough for date format
    Record 2: Rejected - Error on table CHAT_SL, column SL1.
    ORA-01840: input value not long enough for date format
    Record 3: Rejected - Error on table CHAT_SL, column SL1.
    ORA-01840: input value not long enough for date format
    Record 4: Rejected - Error on table CHAT_SL, column SL1.
    ORA-01840: input value not long enough for date format
    I wonder if you could help me.
    Thank you very much in advance.
    Giorgos Baliotis

    SQL> select to_date('Apr 29, 2007 12:05:49 AM','Mon DD, YYYY HH:MI:SS FF3AM') from dual;
    select to_date('Apr 29, 2007 12:05:49 AM','Mon DD, YYYY HH:MI:SS FF3AM') from dual
    ERROR at line 1:
    ORA-01821: date format not recognized
    SQL> ed
    Wrote file afiedt.buf
      1* select to_date('Apr 29, 2007 12:05:49 AM','Mon DD, YYYY HH:MI:SS AM') from dual
    SQL> /
    TO_DATE(
    29/04/07
    SQL> Then, you defined blank space as separator, but there is spaces in your date inside your file. So, you should add double-quotes around the date field like below, and add optionally enclosed by '"' into your ctlfile.
    "Apr 29, 2007 12:05:49 AM" 1060615 "Apr 29, 2007 12:05:35 AM" 306978537730 24026384 chatium.user.userinfo WAP 0
    "Apr 29, 2007 12:12:51 AM" 1061251 "Apr 29, 2007 12:12:27 AM" 306978537730 24026384 chatium.channel.list WAP 0
    "Apr 29, 2007 12:12:51 AM" 1061264 "Apr 29, 2007 12:12:32 AM" 306978537730 24026384 chatium.channel.listdetail WAP 0
    "Apr 29, 2007 12:13:51 AM" 1061321 "Apr 29, 2007 12:13:31 AM" 306978537730 24026384 chatium.user.search WAP 0
    "Apr 29, 2007 12:13:51 AM" 1061330 "Apr 29, 2007 12:13:37 AM" 306978537730 24026384 chatium.user.userinfo WAP 0Example :
    http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14215/ldr_concepts.htm#sthref477
    Nicolas.

  • Problem with date format convertion

    Dear All, i want to convert the current system date to particular format that i have specified below in SimpleDateFormat but when ever i exceute my program it comes in different format
    could you help me to solve the problem
    DateFormat sdf = new SimpleDateFormat("yyyy.MM.dd hh:MM:ss");
    Date today = Calendar.getInstance().getTime();
    String rdate = sdf.format(today);
    Date date = sdf.parse(rdate);
    System.out.println("Current date and time is: "+date);i want my date to be like: *2008.09.11 05:00:17*
    but the program output is: Current date and time is: Thu Sep 11 05:00:17 EEST 2008
    thanks

    shamilsons wrote:
    Dear All, i want to convert the current system date to particular format that i have specified below in SimpleDateFormat but when ever i exceute my program it comes in different format
    could you help me to solve the problem
    DateFormat sdf = new SimpleDateFormat("yyyy.MM.dd hh:MM:ss");
    Date today = Calendar.getInstance().getTime();
    String rdate = sdf.format(today);
    Date date = sdf.parse(rdate);
    System.out.println("Current date and time is: "+date);i want my date to be like: *2008.09.11 05:00:17*
    but the program output is: Current date and time is: Thu Sep 11 05:00:17 EEST 2008
    thanksA java.util.Date is just a long. So when you said "System.out.println("Current date and time is: "+date);" you called the "toString()" method of java.util.Date, which formats it to a String the way you see. You have the date formatted the way you want in the "rdate" String, so try "System.out.println("Current date and time is: " + rdate);" and see if that works out for you.

  • Problem with  date format "dd-MM-yyyy"

    hi all,
    i am using jdev 10.1.3.2
    My application ADF Swing app.
    in my database i have a table employee which contains "birthday".
    my problem is that i must use date format"dd-MM-yyyy".
    i added this format into "formatinfo.xml" file.
    than i choose it in my EO.
    i create a form which contains employees.
    for example i have an employee with a birthday=25-10-1970
    in my text field if user puts "1970-10-25"'which is not the best format) he will have a correct result "25-10-1970"
    but if user puts "25-10-1970" he will have as result "21-02-0031" which is not the real value.
    please help me.
    thanks.
    PS: i did some research before posting but i didn't find yet

    Rouz,
    Did you try what i said before?
    * Open you EntityObject
    * Expand the attribute tree
    * Choose your DOB attribute
    * Choose the Control hints pane on the right
    * Choose Formater: Simple date format
    * Choose Format mask dd-MM-yyyy
    Run your application and try it.
    This is how i change the format and it works perfectly.
    I uses the correct format to show the date and it enables me to edit the date using the format mask dd-MM-yyyy
    Edit: I just tried it myself. I can only reproduce it by removing my mask. Ergo, the application expects the default american format yyyy-MM-dd. By entering a date in the format dd-MM-yyyy the framework will convert it to yyyy-MM-dd and you'll end up with 0031-02-21.
    CONCLUSION follow the steps i discribed above to set your mask and you'll be fine.
    Message was edited by:
    Smolders Johan

Maybe you are looking for