SQL Data Access from database

 Hi Friends,
 I want to access data from database, User will enter Start Date and end date , based on that , data will be get retried.
Is it possible to write a SQL Query, Where A SQL Query will take care user start and end date. Start date and end date is not fixed, it will be vary based on user.
Thanks for co-operation.
Regards,
Pritam A.

Pritama,
Yes, your query looks fine. It should work perfectly. You could alternatively, get input from user into variables and use them in your query as shown below:
declare @user_startdate datetime
set @user_startdate='10/Oct/2013 1:00:04'
declare @user_enddate datetime
set @user_enddate='14/Oct/2013 1:00:04'
SELECT * FROM GT1
WHERE datetime1 BETWEEN @user_startdate AND @user_enddate
Is there anything else you are facing a problem with? Your query is correct and gives no problems..
Thanks,
Jay
<If the post was helpful mark as 'Helpful' and if the post answered your query, mark as 'Answered'>

Similar Messages

  • How to use Sql data source from Essbase 9.3.1

    Hi All,
    How to use Sql data source from Essbase 9.3.1 for ASO cube.Are there any rules and limitations for that.
    Do we need to create any data source connection for this purpose. If there please let me know the dteps to create that connection.
    Regards

    Yes you need to create one DSN connection and you have to use DSN name and login details at the time of building/loading of the outline.
    Create DSN
    Goto Administrative tools -> DataSources (ODBC) and add the DSN name and specify the Server name of SQL and login details and database.
    goto data prep editor and click on File Menu and Click on Open SQL option Next window opens.
    There you have to enter the details of the DSN connection and SQL query to build/load.
    Thanks,
    Prathap

  • Data access from weblogic

    Hi,trying to figure out the most optimum of data access from weblogic. We initially used to do a preparestatement and then execute inside the dopost method of the servlets, but this causes the statement to be parsed everytime. To avoid this we decided to prepare the statements once in the init method of the servlets and do only an execute inside the dopost, but this causes the data in the resutl set objects to be mixed up if two or more users simultaneously accessed the same servlet(resutlsets are not thread safe??). To resolve this problem we did the executes inside a synchronized block but this is not very good for performance.So what is the best way?RgdsHarish

    Make sure you declare your resultset locally.
    Michael Girdley
    BEA Systems
    Learning WebLogic? http://learnweblogic.com
    "Harish" <[email protected]> wrote in message
    news:3acccc04$[email protected]..
    Hi,trying to figure out the most optimum of data access from weblogic. Weinitially used to do a preparestatement and then execute inside the dopost
    method of the servlets, but this causes the statement to be parsed
    everytime. To avoid this we decided to prepare the statements once in the
    init method of the servlets and do only an execute inside the dopost, but
    this causes the data in the resutl set objects to be mixed up if two or more
    users simultaneously accessed the same servlet(resutlsets are not thread
    safe??). To resolve this problem we did the executes inside a synchronized
    block but this is not very good for performance.So what is the best
    way?RgdsHarish

  • Oracle dblink to sql server, accessing multiple database on same sql server under one dblink

    Hi, we have successfully managed to set up an Oracle dblink over to sql server and retrieve data.
    The sql server user were using via the dblink has access to more than one database on the same sql server
    But the question is how in oracle (if at all possible) do you prefix the sql statement to access this ?
    Eg:
    Sqlserver_prod has user sqlserver_user which appears to be set up as default database on sqlserver_db1
    But we have select access to sqlserver_db2
    all work fine as sqlserver_user
    select * from  table_fromdb1
    select * from  dbo.table_fromdb1
    select * from  sqlserver_db1.dbo.table_fromdb1
    as does
    select * from  sqlserver_db2.dbo.table_fromdb2
    over in Oracle
    Oracle_db has dblink sqlserver_prod.world connecting as sqlserver_user
    all working fine
    select * from "table_fromdb1"@sqlserver_prod
    select * from "dbo"."table_fromdb1"@sqlserver_prod
    but how (if at all possible) do I access from oracle
    sqlserver_db2.dbo.table_fromdb2
    without having to create a new sqlserver_db2_user referenced in a new dblink
    if oracle to oracle would be
    select * from remote_oracle_schema.table@remote_oracle_db

    Hi, ok cheers, I see, original gateway was connecting purely at host_name level
    HS_FDS_CONNECT_INFO=sqlserver_host
    Planning to amend this to be
    HS_FDS_CONNECT_INFO=sqlserver_host//sqlserver_db1
    With exisiting dblink
    And to create new gateway
    HS_FDS_CONNECT_INFO=sqlserver_host//sqlserver_db2
    With new exisitng dblink,will see how we get on
    Cheers again

  • CRVS2010 beta - Date field from database does not display in report

    Hi there - can someone please help?!
    I am getting a problem where a date field from the database does not display in the report viewer (It displays on my dev machine, but not on the client machines...details given below)
    I upgraded to VS 2010
    I am using the CRVS2010 Beta
    My development machine is Windows 7 - and so is my fellow developer's
    We are using Microsoft SQL Server 2000
    We run the queries within VS and then we send the data table to VS using .SetDataSource
    We have a few reports which display the date on our dev machines (whether we run the EXE or from within Visual Studio)
    When we roll out to the client machines (running Windows XP SP3) then everything works, except that the date does not display (on quite a few reports)
    This is the only real issue I have had - a show stopper for me
    The rest works well - any input will be greatly appreciated
    Regards,
    Ridwan

    Hi Ridwan,
    After much testing I have it all working now using CRDB_adoplus.dll as a data source ( XML )
    Alter your Config file to look like this:
    <startup useLegacyV2RuntimeActivationPolicy="true">
    <supportedRuntime version="v4.0"/>
    </startup>
    Then using the code below, and CR requires the Schema to be able to read the date format.
    private void SetToXML_Click(object sender, EventArgs e)
    CrystalDecisions.CrystalReports.Engine.ReportDocument rpt = new CrystalDecisions.CrystalReports.Engine.ReportDocument();
    ISCDReportClientDocument rcd;
    rcd = rptClientDoc;
    string connString = "Provider=SQLOLEDB;Data Source=dwcb12003;Database=xtreme;User ID=sb;Password=password";
    string sqlString = "Select * From Orders";
    OleDbConnection oleConn = new OleDbConnection(connString);
    OleDbDataAdapter oleAdapter = new OleDbDataAdapter(sqlString, oleConn);
    //OleDbDataAdapter oleAdapter2 = new OleDbDataAdapter(sqlString2, oleConn);
    DataTable dt1 = new DataTable("Orders");
    oleAdapter.Fill(dt1);
    System.Data.DataSet ds = new System.Data.DataSet();
    // We need the schema to get the data formats
    ds.WriteXml("c:
    sc.xml", XmlWriteMode.WriteSchema);
    //Create a new Database Table to replace the reports current table.
    CrystalDecisions.ReportAppServer.DataDefModel.Table boTable = new CrystalDecisions.ReportAppServer.DataDefModel.Table();
    //boMainPropertyBag: These hold the attributes of the tables ConnectionInfo object
    PropertyBag boMainPropertyBag = new PropertyBag();
    //boInnerPropertyBag: These hold the attributes for the QE_LogonProperties
    //In the main property bag (boMainPropertyBag)
    PropertyBag boInnerPropertyBag = new PropertyBag();
    //Set the attributes for the boInnerPropertyBag
    boInnerPropertyBag.Add("File Path ", @"C:\sc.xml");
    boInnerPropertyBag.Add("Internal Connection ID", "{680eee31-a16e-4f48-8efa-8765193dccdd}");
    //Set the attributes for the boMainPropertyBag
    boMainPropertyBag.Add("Database DLL", "crdb_adoplus.dll");
    boMainPropertyBag.Add("QE_DatabaseName", "");
    boMainPropertyBag.Add("QE_DatabaseType", "");
    //Add the QE_LogonProperties we set in the boInnerPropertyBag Object
    boMainPropertyBag.Add("QE_LogonProperties", boInnerPropertyBag);
    boMainPropertyBag.Add("QE_ServerDescription", "NewDataSet");
    boMainPropertyBag.Add("QE_SQLDB", "False");
    boMainPropertyBag.Add("SSO Enabled", "False");
    //Create a new ConnectionInfo object
    CrystalDecisions.ReportAppServer.DataDefModel.ConnectionInfo boConnectionInfo =
    new CrystalDecisions.ReportAppServer.DataDefModel.ConnectionInfo();
    //Pass the database properties to a connection info object
    boConnectionInfo.Attributes = boMainPropertyBag;
    //Set the connection kind
    boConnectionInfo.Kind = CrConnectionInfoKindEnum.crConnectionInfoKindCRQE;
    //*EDIT* Set the User Name and Password if required.
    boConnectionInfo.UserName = "";
    boConnectionInfo.Password = "";
    //Pass the connection information to the table
    boTable.ConnectionInfo = boConnectionInfo;
    //Get the Database Tables Collection for your report
    CrystalDecisions.ReportAppServer.DataDefModel.Tables boTables;
    boTables = rptClientDoc.DatabaseController.Database.Tables;
    //For each table in the report:
    // - Set the Table Name properties.
    // - Set the table location in the report to use the new modified table
    boTable.Name = "Orders";
    boTable.QualifiedName = "Orders";
    boTable.Alias = "Orders";
    rptClientDoc.DatabaseController.SetTableLocation(boTables[0], boTable);
    //Verify the database after adding substituting the new table.
    //To ensure that the table updates properly when adding Command tables or Stored Procedures.
    rptClientDoc.VerifyDatabase();
    MessageBox.Show("Data Source Set", "RAS", MessageBoxButtons.OK, MessageBoxIcon.Information);
    Thanks again
    Don

  • Essbase administration service. The SQL data access source is greyed out

    Env: EAS 11g Oracle 10g database
    Hi,
    After i tried to install EAS and try to create a rule file, I find out that I am unable to select the datasource from "SQL data sources" field, which has been greyed out. However, I am able to make the connection in another environment that use the same settings. This is a replica of the system.
    1) Is there something with the connection. If yes, what file(s) I need to check and any other things that I need to check. It could be something with the jdbc.ini file perhaps. But when I try to check this ini file, it appears the same with the one that works in the other environment
    kindly need your help
    Rgds,
    Raymond

    To configure data sources on UNIX:
    1.Open the $EPM_ORACLE_HOME/common/ODBC/Merant/x.x/odbc.ini file and add a data source description.
    2.Copy the $EPM_ORACLE_HOME/common/ODBC/Merant/x.x/odbc.ini to $ESSBASEPATH/bin/.odbc.ini.
    3.Create a symbolic link to the $ESSBASEPATH/bin/.odbc.ini from the UNIX user home directory:
    ln -s $EPM_ORACLE_HOME/common/ODBC/Merant/x.x/odbc.ini /home/myfolder/.odbc.ini
    4.Verify that the odbc.ini file in the user home directory matches the odbc.ini file in EPM_ORACLE_HOME/common/ODBC/Merant/x.x.
    If the files do not match, repeat step1 through step3
    The ODBC-64 folder is used when the Linux is a 64 bit.
    Check if these are the steps you followed to create the Data Source.
    The connection to the DSN created can be checked by below steps in Unix..
    [essdev@dshypdev bin]$ pwd
    essdev/hyperion/products/Essbase/eis/server/bin
    [essdev@dshypdev bin]$ ./odbcconfig
    Using the following Environment...
    Env HYPERION_HOME=/essdev/hyperion
    Env TDODBC=. (for Teradata only)
    odbc.ini file name=/essdev/hyperion/common/ODBC-64/Merant/5.2/odbc.ini
    Database Driver Names:
    Db2=/essdev/hyperion/common/ODBC/Merant/5.1/lib/ARdb221.so
    Oracle=/essdev/hyperion/common/ODBC/Merant/5.1/lib/ARora21.so
    Sybase=/essdev/hyperion/common/ODBC/Merant/5.1/lib/ARase21.so
    Informix=/essdev/hyperion/common/ODBC/Merant/5.1/lib/ARifcl21.so
    Teradata=./drivers/tdata.so
    SQL Server=/essdev/hyperion/common/ODBC/Merant/5.1/lib/ARmsss21.so
    ODBC.ini Configuring Utility
    1. List
    2. Add
    3. Delete
    4. Test
    5. Exit
    Select option 4 to test the connection

  • Caching data read from database

    I have a big performace problem in our J2EE application. We use jsp and servlets to process a request. Servlet gets the results from database which are stored in a vector of dataobjects and vector is stored in session. We display only 20 rows in jsp and provide page navigation to view more data by Next and Prev links. The problem is we want to store results in request object instead of session variable but then that data is not availabe for Next and Prev links. We don't want to do another search to view more data. Is there a way to cache the data so that while view more data by page navigation we don't need to hit database since request object would be cleared at that time. I am clueless. I hope I explained the problem properly. Any help on this would be highly appreciated

    You're not clueless, you said it yourself.
    To make info available over multiple requests, you need to use a session variable rather than the request.

  • Reading Data Clusters from Database ??

    Hi at all,
    how can I read Data from a ClusterTable´`?
    In the Database "STXL" is a field "CLUSTR" and "CLUSTD" and i want see the input. But before i can see it, i must read this Data Cluster.
    How does it work``?
    IMPORT tab = itab
    FROM DATABASE stxl(tx)
    ID   wa_TDOBJECT
    TO wa_stxl.

    well, normally you got FM´s which enable you to do selects or whatever with cluster tables.
    in your case it would be FM READ_TEXT or related FM´s. I do ABAP programming for quite a while now, and i never came to the situation where i manually had needed to read a cluster table.

  • Data access from web

    how to POST data to Web servers in Java
    null

    hi there,
    U can copy that data into a excell file in a fixed format. After that using SQL*Loader u can import that data into oracle database.
    But fix one format so that u can easily dump that data into oracle database when ever u want with out much effort.
    Cheers
    Naveen

  • Data access from Access Database

    I want collect some data from access, I have created a frame with swing componet, now when I am searching data with some variable from Access database , it is not comming, but in simple case all data are comming in differnt places in my frame.
    The string which I used is
    st.executeQuery("Select * from student where cid = '+st1+'"
    where st1 is avariable collected some data from the frame, it is tested ok.
    now i never did practice with access, please if there is any wrong .

    Could you include more code please? The single statement you have provided seems fine, but we're not psychic.

  • How to get Date value from database and display them in a drop down list?

    Hello.
    In my Customers table, I have a column with Date data type. I want to create a form in JSP, where visitors can filter Customers list by year and month.
    All I know is this piece of SQL that is convert the date to the dd-mm-yyyy format:
    SELECT TO_CHAR(reg_date,'dd-mm-yyyy') from CustomersAny ideas of how this filtering possible? In my effort not to sound like a newbie wanting to be spoonfed, you can provide me link to external notes and resources, I'll really appreciate it.
    Thanks,
    Rightbrainer.

    Hi
    What part is your biggest problem?? I am not experienced in getting data out of a database, but the way to get a variable amount of data to show in a drop down menu, i have just messed around with for some time and heres how i solved it... In my app, what i needed was, a initial empty drop down list, and then using input from a text-field, users could add elements to a Vector that was passed to a JComboBox. Heres how.
    package jcombobox;
    import java.awt.*;
    import java.awt.event.*;
    import java.util.Vector;
    import javax.swing.*;
    public class Main extends JApplet implements ActionListener {
        private Vector<SomeClass> list = new Vector<SomeClass>();
        private JComboBox dropDownList = new JComboBox(list);
        private JButton addButton = new JButton("add");
        private JButton remove = new JButton("remove");
        private JTextField input = new JTextField(10);
        private JPanel buttons = new JPanel();
        public Main() {
            addButton.addActionListener(this);
            remove.addActionListener(this);
            input.addActionListener(this);
            buttons.setLayout(new FlowLayout());
            buttons.add(addButton);
            buttons.add(remove);
            add(dropDownList, "North");
            add(input, "Center");
            add(buttons, "South");
        public void actionPerformed(ActionEvent e) {
            if (e.getSource() == addButton) {
                list.addElement(new SomeClass(input.getText()));
                input.setText("");
            } else if (e.getSource() == remove) {
                int selected = dropDownList.getSelectedIndex();
                dropDownList.removeItemAt(selected);
        public void init(String[] args) {
            setSize(400,300);
            getContentPane().setLayout(new BorderLayout());
            getContentPane().add(new Main());
    }And that "SomeClass" is show here
    package jcombobox;
    public class SomeClass {
        private String text;
        public SomeClass(String input) {
            text = input;
        public String toString() {
            return text;
    }One of the things i struggled a lot with was to get the dropdown menu to show some usefull result. If the list just contains class references it will show the memory code that points to that class. Thats where the toString cones in handy. But it took me some time to figure that one out, a laugh here is welcome as it should have been obvious :-)
    When the app is as simple as this one, using a <String> vector would have been easier, but this is just to demonstrate how to place classes in a vector and get some usefull info out of it, hope this answered some of your question :-)
    The layout might have been easier to write, than using the toppanel created by the JApplet and then the two additional JPanels, but it was just a small app brewed together in 15 minutes. Please comments on my faults, so that i can learn of it.
    If you need any of the code specified more, please let me know. Ill be glad to,

  • Data access from Application Server - Seeking Opinion

    I am working on a fairly large scale ERP application that is written in Java both on the front end, and middle tier ( using a JBoss application server ).
    All of the database access happens in my app server, and when I wanted to get peoples opinions on the best way to extract and pass data to and from the database from the app server, and of course to and from the client.
    I am using JDBC to make database calls and extra data from the database. This is of course pretty trivial. And I first started writing POJO that represent tables in my database. I then wrote a faily length method that uses reflection to call the setting methods and pass in the objects returned from the database result set. This of course becomes tricky when you start to join multiple tables together. And often you only need a small subset of columns in a table and don't require an object with all the columns from the table ( some set, and some as null objects ).
    So then I decided I was use a combination of ArrayList objects and HashMap's to store the data. If a result set returned multiple rows, it would return an ArrayList of HashMap objects. Each hash map would contain the data for that row, and the hash map keys are the column names.
    This seems to work pretty well and resolves the problem of joining multiple tables together and keeping track of which columns get stored in which objects.
    Does anyone have a different solution or idea as to how to handle this? And thoughts or ideas would be greatly appreciated.

    bryano wrote:
    Let me pose a quick Hibernate question as well.Let me recommend that you not be so thin-skinned about responses.
    >
    If you had a table that had 40 columns in it and say 1000 rows. And you needed to run a query that returned all 1000 rows, but you only needed two out of the
    40 columns. Would it be better to extract those two columns into the HashMap / ArrayList collection I mentioned in my original post? Or would using something like Hibernate and a class that mapped all of the columns in the table be okay?Why not just map the columns you needed in Hibernate? Who said you had to map all 40 and have them be null?
    My concern is on efficiency,
    and I was wondering if building 1000 objects that each have 40 members that only 2 are populated is the most efficient way of extracting the data.Doesn't sound very efficient.
    I will admit, my knowledge of Hibernate is limited at best so I may be missing a component of Hibernate that would allow you to only extract the columns you required, but you are still working with an object that has 38 null value objects for the columns you didn't require.I don't believe you're required to map every column in a table.
    %

  • Stroring data taken from database as a variable

    Hi there I;m having a problem and I was wondering if anyone can help me?
    I am trying to extract data from a MySQL database and store the variables so I can use them in another bean...
    so far I am getting a SQL exception error but I dont know what Im doing wrong.......
    My bean code is :
    public int getAge(int age) throws SQLException, Exception{
    if(con != null){
    try{
    String userName = null;
    ResultSet rs;
    Statement stmt = con.createStatement();
    rs = stmt.executeQuery("SELECT (age) FROM gymuser WHERE Username='" userName "'");
    age = rs.getInt("age");
    return age;
    } catch(SQLException sqle){
    error = "SQLException: could not search gymuser";
    throw new SQLException(error);
    catch(Exception e){
    error = "An exception occured while searching gymuser";
    throw new Exception(error);
    } else {
    error = "Exception: connection to database was lost";
    throw new Exception(error);
    The JSP that calls this is :
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%@page import="java.sql.*, java.io.*, java.util.*;"%>
    <jsp:useBean id="details" scope="session" class="fitness.DBQuery" />
    <jsp:useBean id="conn" class="fitness.DBConnect" />
    <jsp:useBean id="currentuser" scope="session" class="fitness.currentuserBean" />
    --%>
    <%--
    <%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
    --%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>GetDetails</title>
    </head>
    <body>
    <h1>GetDetails</h1>
    <%
    int age = 0;
    String userName = currentuser.getName();
    conn.connect();
         details.setCon(conn.getCon());
         details.getAge(age);
    conn.disconnect();
    %>
    </body>
    </html>
    Any help you have to offer would be greatly appreciated as Im desperate!! :-)

    Thanks for your help, greatly appreciated....
    I havent ever had to use DTO's before as this is the first time in my project where I need t use databasa data as variables in other classes.....so I should have a classthat looks like this ??: /*
    * GymUser.java
    * Created on 26 April 2007, 13:02
    * To change this template, choose Tools | Template Manager
    * and open the template in the editor.
    package fitness;
    import java.sql.*;
    import java.io.*;
    import java.util.*;
    import java.util.Date;
    import java.io.Serializable;
    * @author Hegstatic
    public class GymUser implements Serializable{
        /** Creates a new instance of gymUser */
         private String error;
         private String userName;
         private int age; // + getter + setter
        private double weight;
        private String gender;
        public int getAge(){
             return age;
        public void setAge(int i)
             age = i;
        public double getWeight()
            return weight;
        public void setWeight(double d)
            weight = d;
        public String getGender()
            return gender;
        public void setGender(String string)
            gender = string;
        Connection con;
        private String Frankie;
    public GymUser getGymUser()
                     if(con != null){
                     try{
                    ResultSet rs;
                    Statement stmt = con.createStatement();
                   rs = stmt.executeQuery("SELECT * FROM gymuser WHERE Username='" +Frankie+ "'");
                    List<GymUser> gymUsers = new ArrayList<GymUser>();
                    while (rs.next()) {
                        GymUser gymUser = new GymUser();
                        gymUser.setAge(rs.getInt("age"));
                        gymUser.setWeight(rs.getDouble("weight"));
                        gymUser.setGender(rs.getString("gender"));
                        gymUsers.add(gymUser);
        return gymUsers;
                     } catch(SQLException sqle){
                   error = "SQLException: could not search gymuser";
                    throw new Exception(error, sqle);
                   catch(Exception e){
                   error = "An exception occured while searching gymuser";
                   throw new Exception(error);
                    } else {
                   error = "Exception: connection to database was lost";
                   throw new Exception(error);
        }The IDE is telling me that the value I have for
    return gymUsers; is wrong...
    Was just wondering if I am going in the right direction and how would I call the variables age, weight, gender in a JSP page??
    Again Thank you !!
    Hegtic

  • How do I get dates pulled from database to display in Spanish?

    I'm pulling a date from a MySQL database and need to have it
    display in Spanish. If it were in English, these are the two
    statements I would be using:
    #DateFormat(event_date,"mmmm")#
    #DateFormat(event_date,"mmm d")#
    I tried using <cfset SetLocale("Spanish (Standard)")>
    in my Application.cfm , but it didn't seem to work. I'm not really
    sure how it is supposed to be used or even if it would work if I
    were using it correctly.
    Any help would be appreciated.
    Thanks -CaddyX

    Bagger Vance wrote:
    > setLocale("es_ES"); // or whatever locale you're using
    for "Spanish"
    > // all the subsequent LS functions will use this locale
    > writeoutput("#lsDateFormat(eventDate,"FULL")#");
    >
    >
    >
    > Paul, Thanks for responding. I'm still not sure how to
    make it work. Do I just
    > put <cfset SetLocale("es_ES")> somewhere in the
    document? That didn't seem to
    > change the result in the following code:
    you can put it at the top of pages that need to be localized
    or better yet in
    your application cfm/cfc.
    >
    <cfoutput>#DateFormat(get_event.event_date,"mmmm")#</cfoutput>
    yes it won't change that, the regular cf functions all use
    en_US locale. you
    want the "LS" functions (re-read the code snippet above).

  • Having problem with adding and reading dates to/from database !!!

    Hi
    I am new in J2ME
    I am trying to code a simple software.
    My problem is with dates.
    I have a datefield on my menu and the user will choose the date from here. By default, datefield shows todays date. But when I try to write that date to database using rms, date value transforms to java.util.Date@acfdb0fe.
    As I read from tutorials this is common problem of date class, so I tried to use calendar class.
    But with Calendar class I cannot let user to choose date from screen like DateField. datefield dowsn't work with calendar.
    later, I will use that date for sorting records
    Summary : I need a sample code that read date from screen (preferably with datefield), write it to recordstore. and then read it from recordstore asnd write to screen.
    I searching internet for a sample code through days.
    Please help me
    Thanks

    Hi,
    The best i would suggest is instead of storing the date as 19 Jan 2004 or something like this better store the date in milliseconds.
    DateField df = new DateField();
    Date d = df.getDate();
    long ms = d.getTime();
    store the value of ms in RMS. This is the commonly used way to store date in RMS for j2me.
    You can get back date using
    Date d = new Date(ms);
    DateField df = new DateField();
    df.setDate(d);
    Prabhu.

Maybe you are looking for

  • How Can I Safely Delete a RoboHelp 9 Project?

    I am learning/evaluating RoboHelp 9 using IconLogic's "Essentials of Adobe RoboHelp 9 HTML".  This book  has excellent step-by-step lessons and contains student data files to make it easier to learn.  The student lessons were downloaded and unzipped

  • Inventory Adjustment report gives the error

    Hi In my project we are using the stanard report that are being given by the Oracle. the current Inventory adjustment report of oracle retail 13.1 is throwing an error while running with the parameter 'ALL'. The error that we are getting is ORA-01830

  • Cover flow image all pixelate. How can I fix it?

    in coverflow, some of the graphics ok the album cover are pixelatwd and mosaic looking. It's about every third of fourth album cover. In non-cover flow view they are all fine. What could have caused this and how can I fix it? In iTunes the graphics a

  • Adobe indesign cs4 (New font instalation)

    How can I install new font from adobe Indesgn cs4? Please help me to the procedure of install the new font! I have use the following steps--- Windows>Control Panel>fonts>Install new fonts But Its does not work.

  • How to backup hard drive

    I have a an empty external hard drive and my internal drive is filling up and has all my imporant documents/photos/music etc. How do I make a backup of my internal drive to the external drive? Thanks.