Date format problem in webdynpro java

Currently, the date format that gets displayed in our webdynpro java application is MMDDYYYY...i am assuming this is because the web dynpro application has language resource set to en_US as its Current locale in the web dynpro deployed content section.  Howver i want it to display as DDMMYYYY. I have changed the default properties in visual admin for web dynpro from en to en_GB however this has no impact what so ever as the current locale is always set to en_US even after the change so am wondering this property is hidden some where else.  Now the web dynpro i am talking about is a adobe portal application. Could you give me any pointers as to where else i can look for or how i can change the current locale properly ??
Regards
Kalyan

Hi.
Also this link could help you.
http://help.sap.com/saphelp_nw04s/helpdata/en/18/f3674039c6c549e10000000a1550b0/content.htm
In special the table showing the order the locale is set in the web dynrpo application.
Also it is shown in the last pages of this document, [Web Dynpro for Experts|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/58a7e390-0201-0010-abb1-8eec7eb7a2ec?quicklink=events&overridelayout=true].
And finally you may use the sap.locale request parameter, how it's defined [here|http://help.sap.com/saphelp_nw04/helpdata/en/f4/651741f163f023e10000000a155106/frameset.htm]. You must add ?sap-locale=en_GB to url.
Manuel Loayza.

Similar Messages

  • Date format problem in webdynpro

    We are trying to display the join date of employees  in a table. It gives mm/dd/yyyy format.
    We want the date in dd/mm/yyyy format .Can anyone help me with the code for this?

    Anzar,
    If the value is coming from the backend and you just want to display as dd/MM/yyyy then in wdDoInit() of your View do the following --> get the current date value, format it as per your need and then set it back.
         // Check the size of the nodeelement which contains your atribute.
         int size = wdContext.node<NodeName>().size();
           // Loop over and set the value
         for (int i = 0; i < size; i++)
              String strJoinDtModel = wdContext.current<NodeName>Element().get<AttributeName>.toString();
              String strNewDtJoin = formatDate("strJoinDtModel");
              wdContext.current<NodeName>Element().set<AttributeName>(strNewDtJoin);
    So if u have following hierarchy
    Employee (ModelNode)
    |---- JoinDate (Model Attrribute)
    then NodeName = Employee and AtrributeName = JoinDate in above code snippet.
    You will need to create a formatDate() method as follows:-
    public String formatDate(String strDate)
         SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy"); // Note the uppercase for month.
         String newDate =  sdf.format(strDate);
         return newDate;

  • Date Format problem...

    Hi users,
    Forte version : 2.e.2 and ForteWebSDK
    Datacase : Oracle
    We have a problem with a simple HTML text field which acccepts
    a date. When we try to update the record with some date, the following
    exception occurs:
    24-Jun-1998 04:32:28 : XV01086 : Execute failed for SQL statement in
    project Rap
    tServices, class RaptSqlMethods, method updateActivity, methodId 104,
    line 51, e
    rror from database is:
    ORA-01830: date format picture ends before converting entire input
    string
    The Oracle manual says that the above exception occurs when there are
    some extra characters on that field, which is not the case. In fact,
    we raise our own exception for the cases like : o1-Apr-1997,
    01-apr-97 etc. The correct format is 01-apr-1998.
    Same date soemtimes is added to the database successfully. Waht I mean
    to say that the exception deos not occur consistently.
    We just conevert the String taken from the HTML field into a Forte
    DateTimeData Object and send it to database. May be, the conversion
    part is causing the problem. But, once again the problem is not
    consistent.
    Any ideas in this will be appreciated.
    Thanx in advance
    -Rajeev Talwar
    Get Your Private, Free Email at http://www.hotmail.com
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    We had the same problem when our application first went live. The
    default date format for our Oracle database is 'dd-mmm-yy' without the
    time component. The default format for datatype DateTimeData is
    'dd-mmm-yyyy hh:mm:ss'. Since we did not want to change the default date
    format for the Database, we included in our service partitions an Alter
    Session statement to change the NLS_Date_format attribute in Oracle to
    conform to the Forte DateTimeData format. It worked.
    Kam Chow
    Mazda Australia
    -----Original Message-----
    From: Gary F Giger [mailto:[email protected]]
    Sent: Thursday, June 25, 1998 4:11 AM
    To: Rajeev Talwar
    Cc: [email protected]
    Subject: Re: Date Format problem...
    I was having the same problem a few weeks back when I would
    read/write
    dates to Oracle. I was using objects of type DateTimeData and I would
    occasionally get errors like you said you were. I found discovered my
    problem. Sometimes I would process a null date and would get an error.
    So to
    resolve this issue, I simply changes my objects of type DateTimeData to
    type
    DateTimeNullable. This enabled my Forte Application to handle regular
    dates
    as well as null dates. I have not gotten any oracle errors since then
    with
    regards to dates. Hope this helps.
    Rajeev Talwar wrote:
    Hi users,
    Forte version : 2.e.2 and ForteWebSDK
    Datacase : Oracle
    We have a problem with a simple HTML text field which acccepts
    a date. When we try to update the record with some date, the following
    exception occurs:
    24-Jun-1998 04:32:28 : XV01086 : Execute failed for SQL statement in
    project Rap
    tServices, class RaptSqlMethods, method updateActivity, methodId 104,
    line 51, e
    rror from database is:
    ORA-01830: date format picture ends before converting entire input
    string
    The Oracle manual says that the above exception occurs when there are
    some extra characters on that field, which is not the case. In fact,
    we raise our own exception for the cases like : o1-Apr-1997,
    01-apr-97 etc. The correct format is 01-apr-1998.
    Same date soemtimes is added to the database successfully. Waht I mean
    to say that the exception deos not occur consistently.
    We just conevert the String taken from the HTML field into a Forte
    DateTimeData Object and send it to database. May be, the conversion
    part is causing the problem. But, once again the problem is not
    consistent.
    Any ideas in this will be appreciated.
    Thanx in advance
    -Rajeev Talwar
    Get Your Private, Free Email at http://www.hotmail.com
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive<URL:http://pinehurst.sageit.com/listarchive/>
    Gary Giger
    Raytheon Systems Company
    300 Science Park Road
    State College, PA. 16804
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>
    This message has successfully passed virus checking.
    Mazda Australia takes every precaution to ensure email messages are virus free. For complete protection, you should virus test this message.
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

  • Data format problem

    Hello All
    Can anyone help me to solve this data format problem? On the top of my program, I have declare the two variables "purchasePrice" and "purchaseAmount" as double. I dont know why, the compiler still think I didnt initialize this two variables? I have printed the error message below the code.
    Thanks for your help : )
    Jen
    =============================================================================
    double purchasePrice, purchaseAmount, GPS, total_gain, amount;
    //Find the purchase stock price
         rs = stmt.executeQuery("SELECT Price FROM PORTFOLIO WHERE Username = '"+ username+"' AND Symbol = '"+strsymbol+"'");
         while (rs.next()){
              purchasePrice = rs.getDouble("Price");
    //Calculate the amount of Gain Per Share
    GPS = intask - purchasePrice;
    //Find the purchase stock amount
    rs = stmt.executeQuery("SELECT Amount FROM PORTFOLIO WHERE Username = '"+ username+"' AND Symbol = '"+strsymbol+"'");
         while (rs.next()){
              purchaseAmount = rs.getDouble("Amount");
    //Calculate the amount of Total Gain
    total_gain = amount - purchaseAmount;
    =============================================================================
    Error message:
    variable purchasePrice might not have been initialized
    [javac] GPS = intask - purchasePrice;
    [javac] ^
    variable purchaseAmount might not have been initialized
    [javac] total_gain = amount - purchaseAmount;
    [javac] ^
    [javac] 2 errors

    Instance and class variables are automatically initialized to their default values if they are not initialized explicitly, but local variables are not. They have to be initialized explicitly before they can be referenced.
    In your code:
        while (rs.next()){
            purchasePrice = rs.getDouble("Price");
        ...purchasePrice is initialized only if rs.next() returns true. purchaseAmount has the same problem. To avoid this problem, you could declare them by:
    double purchasePrice = 0;
    double purchaseAmount = 0;

  • Date format problem in web dynpro java

    Currently, the date format that gets displayed in our webdynpro java application is MMDDYYYY...i am assuming this is because the web dynpro application has language resource set to en_US as its Current locale in the web dynpro deployed content section.  Howver i want it to display as DDMMYYYY. I have changed the default properties in visual admin for web dynpro from en to en_GB however this has no impact what so ever as the current locale is always set to en_US even after the change so am wondering this property is hidden some where else.  Now the web dynpro i am talking about is a adobe portal application. Could you give me any pointers as to where else i can look for or how i can change the current locale properly ??
    Regards
    Kal

    The date format in the Web Dynpro Java Application depends upon locale. At runtime WDJ will do the following process to get the current locale for the date format to be determined.
    1. First the WDJ Application will check for the locale set for the user in UME.
    2. If there is no default locale in UME, then the it will check for the locale in the in the browser which in most cases by default is en-us.
    3. If not, then it will check for the sap.systemLocale in the Propertysheet default of Visual Admin
    4. If there no locale specified in Visual Admin, itu2019s taken from the WAS JVM
    Please check the below SAP Note
    http://help.sap.com/saphelp_nw04/helpdata/en/a0/58db515b95b64181ef0552dc1f5c50/frameset.htm
    Regards,
    Chandran S

  • Data Format Problem Pls Help Me

    Hai,
    I try to insert the date values in the following format the error is occurred,
    insert statement:
    insert into temp values (to_date(?,'YYYY/MM/DD'))
    prepstat_insert.setString(1, end_date);
    Already the date values are stored in the following format
    2005-05-21 16:12:37
    The actual Error is
    " invalid value for DATE, TIME or TIMESTAMP field "
    Please give me any idea for how to recover this problem
    Thankx

    Try setting Date instead of a string. To do that Convert your String to a java.util.Date Object, Convert this to java.sql.Data object and on your prepared statement do a setDate(SQLDateObj) instead of String.
    P.S: Assuming that your column type in the DB is of type Date and not varchar2
    Regards,

  • XML Publisher to Excel Report : Date format problem

    Hi,
    I am trying to create an Excel report with XML Publisher. I have an issue with the Date Fomatting.
    In the XML template, I have set the "Date" column in date format. But the excel output report "Date" column returns as "General text" (string) and it is sorted as text, not as date.
    Can anyone please help me out?
    Thanks!!!

    Hi,
    Did this post solve your problem? I have the same issue that I need to solve.
    I have an xsl-fo template with dates in it.
    The dates are in english.
    My excel is setup to use danish.
    When I export to excel it knows the month jan, feb, mar, apr, ... which are the same in danish and english.
    But months where it differs like may (danish maj) the cell is a general text instead of date.
    Is there anyway you can set/transform the date in the xsl-fo template so it does not care about the language in excel?
    Thank you in advance.
    BR Kenneth

  • Binding and displaying data to table in webdynpro java

    hi all,
    i want to know how to bind the output values to table in webdynpro java.
    i know how to bind values in context to table,but if we want to display the values from database(back end ) and display in table present in the view.
    eg: i have table in view and want to get values from backend(SQL server) and display it in that table.
    plz help me to know ..
    thanks
    sirisha

    Hi Saisirisha,
    Try this.
    1> Take a Value Node(Employee) cardinality 0..n.
    Employee Structure
    Employee
    |------Surname(Attribute)
    |------FirstName(Attribute)
    |------Category(Attribute)
    2> Bind this value node(Employee) in the View datasource of table.
    3> Try the code inside wdDoInit method.
    try {
         // Load the JDBC-ODBC bridge
         Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
         // specify the ODBC data source's URL
         String url = "jdbc:odbc:SSPer";
         // connect
         Connection con = DriverManager.getConnection(url,"North","Ken");
         // create and execute a SELECT
         Statement stmt = con.createStatement();
         ResultSet rs = stmt.executeQuery
         ("SELECT Surname,FirstName,Category FROM Per");
         while (rs.next()) {
         // get current row values
         String Surname = rs.getString(1);
         String FirstName = rs.getString(2);
         int Category = rs.getInt(3);
         //create table row and add the value in the table
         IPrivate<Put View Name>.IEmployeeElement empElm = wdContext.createEmployeeElement();
            empElm.setSurname(Surname);
         empElm.setFirstName(FirstName);
         empElm.setCategory(Category);
         wdContext.nodeEmployee().addElement(empElm);
         // close statement and connection
         stmt.close();
         con.close();
    } catch (java.lang.Exception ex) {
         wdComponentAPI.getMessageManager().reportException("Exception : "ex.getMessage()+,true);
    http://www.developer.com/java/data/article.php/3417381
    Regards,
    Mithu

  • Quicken 2007 date format problem in Mavericks

    Objective: Get date format in dd/mm/yyyy format in Quicken 2007 (Lion compatible version).
    Current OS: Mavericks 10.9.4
    Hardware: Retina MacBook Pro & iMac 27" 3.2Ghz
    Problem:
    On my rMBP with Mavericks 10.9.4, I’m able to get Quicken 2007 data in dd/mm/yyyy format, as desired.
    On my new iMac (late 2013) with 10.9.4, Quicken recognises the System date formats dd/mm/yyyy (setting up a new register shows System date format) but the registers and data are all in m/d/yy.
    Quicken prefs are set to Canadian, so date formats should automatically be in dd/mm/yyyy, but aren't.
    The Quicken data file is identical on both Macs. The original file goes back to 1991, and has been through all Mac OS iterations since then.
    Pre-Lion, I remember that the workaround was to set the Language & Region to something (English / US, don’t remember which) and then change date formats. Anyway, the dd/mm/yyyy stuck, through Lion and Mavericks on my rMBP, but is causing a problem in the iMac.
    My guess is that Quicken is unable to / blocked out from accessing System date formats in Mavericks 10.9.4.
    Wondering if there’s some way to make Quicken access the Mavericks System date format, and stick to it?
    Possible approach: If some expert in these forums knows how Mavericks works under the hood, how it allows other apps access to System Prefs like date formats etc., perhaps a script or Terminal command could force Quicken 2007 to recognise and accept date formats from System Prefs (Language & Regional settings).
    I'd really appreciate the help; needless to say, the Quicken data is vital to my work.

    Hi Marlon,
    The OS Local definitions. Different countries have different date formats for their location. Check the date format of the OS CultureInfo settings.
    Regards,
    Vítor Vieira

  • Date format Problem in forms&reports Services 10g

    Hi Dears,
    I Faced a problem during running reports ( i am using forms& Reports Services 10g), when i pass the parameters via parameter form to the report (built in forms10g Rel 2.0) its appearing in arabic like (25-يناير-2010) as my Date Formate is (DD-YYYY-MON) and NLS_LANG parameter is defined as Arabic_Saudi arabia.AR8MSWIN1256 so as a result report is not running due to unknown Date formate, how can i change the Same Date format (DD-YYYY-MON) to appear in english like (25-2010-JAN)
    Thanks

    You could specify the parameter as type VARCHAR2, explicitly cast it (maybe to DD.MM.YYYY) when you pass it from forms and cast it back in your query, like TO_DATE(:P_PARAM, 'DD.MM.YYYY')

  • Date Format problem in ABAP Proxy

    Hi All,
    We have a Inbound ABAP proxy which recieves data from XI.
    We use a date field in that which is defined as DATS datatype.
    When we trigger the interface from XI with date in format YYYYMMDD, we are getting an exception.
    when the date is sent in format YYYY-MM-DD, the interface is run successfuly.
    when we test the interface in SPROXY transaction the date is displayed in YYYY-MM-DD format.
    does it have anything to do with the defenition of the date format in XI?
    I want to know whether DATS format in XI is different from ABAP?
    should the date that is sent from XI be in YYYY-MM-DD format all the time.
    Kindly suggest a solution for the date problem when it is passed from XI to ABAP proxy

    Hi Uday,
    Check the pattern used in XI/PI for the date definition.
    If it's set to:
         pattern="[0-9]-[0-9]-[0-9]"
    Then it will enforce the pattern. You could try changing the pattern in XI to exclude the hyphen then you have a normal DATS format.
    Regards, Trevor

  • Date formating Problem

    Hi Experts,
    Please guide me i am alone here.
    I Developed one BDC program For IW51.
    I want to wirite the condition for already exitting record based on the date.
    So i select the data from VIQMEL(view).
    I am getting the problem with date format, when i am selecting the data the date format coming like yymmdd,
    but the tcode updating the format is like ddmmyy. 
    please guide me how can i solve this problem.
    Please give any sample code for this scnario.
    Thanks Advance
    Edited by: krishnab121 on Feb 18, 2011 6:32 AM
    Moderator Message: Date related questions are not allowed.
    Edited by: kishan P on Feb 18, 2011 11:27 AM

    Hi,
    <<removed by moderator>>
    Close the thread if answered correctly.
    Regards,
    Saurabh
    MOderator Message: Do NOT answer basic questions. Do NOT ask the Poster to close his questions. Thats not your job and thats against the rules of the forum.
    Edited by: kishan P on Feb 18, 2011 11:28 AM

  • Date Format Problem in Custom Report

    Dear all ,
    I am generating SQL statement for the report , i am passing (param_date from ) and (param_date to) to get data from SITs , and there is tow segments in the SITs : (SIT_date from ) and (SIT_date to) also ,, getting the data from the SITs by comparing the dates for the SIT and the parameters ,,, i am facing problem in the date format , ,, could any one please help me what is the format that i can compare the between dates in the SIT and the Parameters ???
    Best Regards
    Edited by: user6781803 on Jan 3, 2010 7:28 AM

    >
    ... i am facing problem in the date format ...
    >
    What is the problem ? Pl also post full versions of your OS and EBS.
    HTH
    Srini

  • InputDate Column Filter Date Format Problem

    Hi,
    I have an af:table with filterable columns and some of these columns are based on Timestamp VO attributes.
    When I enter a date filter - either manually or from the associated date picker, the filter is applied correctly using a date format of dd/MM/yyyy.
    However, when the table is subsequently refreshed, the filter value is still present but has been re-formatted to "yyyy-MM-dd hh:mi:ss" format (default format for a Timestamp datatype?). The an error appears in the column filter component - "Error: The date is not in the correct format".
    If I want to retain the filter value across queries, how can this be achieved?
    My table column is defined as follows:
    <af:column sortProperty="#{bindings.ViewDataVO1.hints.LastReadingDate.name}"
                                                   filterable="true" sortable="true"
                                                   headerText="#{bindings.ViewDataVO1.hints.LastReadingDate.label}"
                                                   id="c59"
                                                   rendered='#{bindings.ViewDataVO1.hints.LastReadingDate.displayHint != "Hide"}'
                                                   displayIndex="#{bindings.ViewDataVO1.hints.LastReadingDate.displayHeight}">
                                            <f:facet name="filter">
                                                <af:inputDate value="#{vs.filterCriteria.LastReadingDate}" id="id4">
                                                    <af:convertDateTime
                                                                        pattern="#{bindings.ViewDataVO1.hints.LastReadingDate.format}"/>
                                                </af:inputDate>
                                            </f:facet>
                                            <af:outputText value="#{row.LastReadingDate}" id="ot59">
                                                <af:convertDateTime pattern="#{bindings.ViewDataVO1.hints.LastReadingDate.format}"/>
                                            </af:outputText>
                                        </af:column>I've tried messing with the properties of the af:convertDateTime component, but I'm thinking the problem is in the population of the filter facet inputDate with the vs.filterCriteria.LastReadingDate value. This does not appear to be re-formatted for display - but I don't know how to manipulate this value...
    Or is there a better way? This seems more complicated than it should be...?
    By the way, I am using JDeveloper 11.1.2.1.0 for my development.
    Thanks.

    Does it work fine if you change the pattern for convertDateTime?
    I.e
    change
    <f:facet name="filter">
                                                <af:inputDate value="#{vs.filterCriteria.LastReadingDate}" id="id4">
                                                    <af:convertDateTime
                                                                        pattern="#{bindings.ViewDataVO1.hints.LastReadingDate.format}"/>
                                                </af:inputDate>
                                            </f:facet>to
    <f:facet name="filter">
                                                <af:inputDate value="#{vs.filterCriteria.LastReadingDate}" id="id4">
                                                    <af:convertDateTime
                                                                        pattern="dd/MM/yyyy"/>
                                                </af:inputDate>
                                            </f:facet>-Arun

  • Web service date format problem

    Hi, I am using a web service from another R/3 server. Its date format is like this..
    - <xsd:simpleType name="date">
    - <xsd:restriction base="xsd:string">
      <xsd:maxLength value="10" />
      <xsd:pattern value="\d\d\d\d-\d\d-\d\d" />
      </xsd:restriction>
    when I created a Proxy class, the date field  length is 8.
    I write my code and tryed execution. Its not giving any result and no exceptions also.
    I think the problem is with Date field..
    Suggest me how to solve this problem.
    Regards,
    Dhanunjaya Reddy

    Hi Dhanunjaya,
    If you are calling web service from your code, then it is executing like this->
    Your Code--> Proxy---> Already existing web service
    You are making  a call to proxy, not to web service directly.
    And in proxy it is defined as type D( with length 8) which is equivalent to YYYYMMDD.
    So try passing the value  YYYYMMDD(eg 20070505) from your code.
    Regards,
    Piyush
    YYYYMMDD

Maybe you are looking for

  • Strange digital artifacts at the end of each song importing via iTunes

    I've tried a few variations on archive searches and wasn't able to find an answer to this: In ripping some of my CD's into iTunes (either Apple Lossless or WAV) I've been getting some very odd, brief digital artifacts at the end of each songs on a CD

  • Problem concerting spool to PDF format

    Hi all, I am trying a small program to write ABAP list to spool, and within the same program I am trying to convert the spool into PDF format. I am including all the code , please can any one check and tell me where I am going wrong. I am getting a m

  • Table of  Classification of SALes order

    Dear Guru ., Please sugest me the table  for Classification of SALes order. Tx. RAjnish Sahay

  • Issue with addPartialTarget method (Pop-up window)

    Hi, I am facing an issue with addPartialTarget method (pop-up window case). Please refer the thread Re: popup dialog problem If we are using addPartialTarget method, should the managed bean be in session scope? I've set it is in request scope. It wor

  • Employer Identification Number - required?

    Hello, According to many step by step documents: "How to convert to Multi - Org" I stuck on following step: 6. Complete the minimum required 'other' information for each classification selected; a) GRE/Legal entity; must define an employer identifica