Storing data

Hi all
Im designing a program to help with booking guets into a small hotel, When a persons details are entered, what would be the best way to store each customers details. Im quite new to java so if what i suggest is a bad idea then please guide me in the correct path.
Im designing a customer class which has the following attributes:
name, address, telNo with all the necessary methods....but what i dont understand is, when a customer is added the details are stored as the variables in the class
what happens when a second customer is added, what happens to the data from the first customer. I need to save this.
any help will be grately appriciated
D_H

Ok, that makes more sense. There was a guy who posted here a while ago who had actually been given a freelance job to write a Java solution, and he had absolutely no clue what he was doing. Just wanted to make sure you're not similar....
You could see it like this. The class is the blueprint for the objects you create from it. You can instantiate any number of objects from a class. Kind of like when an architect creates the blueprints for a house, then a contractor can take them and build a hundred houses based on those blueprints. They will basically all be the same execept for some properties that can be changed, like the color. (I know you guys in the UK like building long rows of similar looking houses so I thought you might appreciate this comparison...)
If you have a class Customer like this
public class Customer{
    private String name;
    public Customer(String n){
        name = n;
    public String getName(){
        return name;
}then you can instantiate multiple objects of that class
Customer cust1 = new Customer("Han Solo");
Customer cust2 = new Customer("Chewbacca");These are separate instances of the same class, each holds it's own data and are completely separate, except thay are based on the same blueprint (class).
Does this make it a bit clearer for you? There's a lot of good books and tutorials on this stuff, but I agree it can be hard in the beginning to get your head around this stuff. Don't worrym if you keep at it it will become trivial.

Similar Messages

  • SAP paging overflow when storing data in the ABAP/4 memory.

    I am trying to create a data source in  BI7.0 in the Datawarehousing Workbench. But along the process when i need to select a view i get an error detailed in the following error file extract: Please go through and assist.
    untime Errors         MEMORY_NO_MORE_PAGING
    Date and Time          06.06.2009 14:21:35
    Short text
    SAP paging overflow when storing data in the ABAP/4 memory.
    What happened?
    The current program requested storage space from the SAP paging area,
    but this request could not be fulfilled.
    of this area in the SAP system profile.
    What can you do?
    Note which actions and input led to the error.
    For further help in handling the problem, contact your SAP administrator
    You can use the ABAP dump analysis transaction ST22 to view and manage
    termination messages, in particular for long term reference.
    Error analysis
    The ABAP/4 runtime system and the ABAP/4 compiler use a common
    interface to store different types of data in different parts of
    the SAP paging area. This data includes the
    ABAP/4 memory (EXPORT TO MEMORY), the SUBMIT REPORT parameters,
    CALL DIALOG and CALL TRANSACTION USING, as well as internally defined
    macros (specified with DEFINE).
    To store further data in the SAP paging area, you attempted to
    allocate a new SAP paging block, but no more blocks were
    available.
    When the SAP paging overflow occurred, the ABAP/4 memory contained
    entries for 20 of different IDs.
    Please note:
    To facilitate error handling, the ABAP/4 memory was
    deleted.
    How to correct the error
    The amount of storage space (in bytes) filled at termination time was:
    Roll area...................... 8176
    Extended memory (EM)........... 13587912
    Assigned memory (HEAP)......... 0
    Short area..................... " "
    Paging area.................... 40960
    Maximum address space.......... " "
    By calling Transaction SM04 and choosing 'Goto' -> 'Block list',
    you can display an overview of the current roll and paging memory
    levels resulting from active users and their transactions. Try to
    decide from this whether another program requires a lot of memory
    space (perhaps too much).
    The system log contains more detailed information about the
    termination. Check for any unwanted recursion.
    Determine whether the error also occurs with small volumes of
    data. Check the profile (parameter "rdisp/PG_MAXFS", see
    Installation Guidelines).
    Is the disk or the file system that contains the paging file
    full to the extent that it cannot be increased, although it has
    not yet reached the size defined in the profile? Is the
    operating system configured to accommodate files of such a
    size?
    The ABAP processor stores different types of data in the SAP
    paging area. These include:
    (1) Data clusters (EXPORT ... TO MEMORY ...)
    (2) Parameters for calling programs (SUBMIT REPORT ...),
    Dialog modules (CALL DIALOG ...) and transactions
    (CALL TRANSACTION USING ...)
    (3) Internally defined program macros (DEFINE ...)
    Accordingly, you should check the relevant statements in a program
    that results in an overflow of the SAP paging area.
    It is critical when many internal tables, possibly with
    different IDs, are written to memory (EXPORT).
    If the error occures in a non-modified SAP program, you may be able to
    find an interim solution in an SAP Note.
    If you have access to SAP Notes, carry out a search with the following
    keywords:
    "MEMORY_NO_MORE_PAGING" " "
    "SAPLWDTM" or "LWDTMU20"
    "TABC_ACTIVATE_AND_UPDATE"
    If you cannot solve the problem yourself and want to send an error
    notification to SAP, include the following information:
    1. The description of the current problem (short dump)
    To save the description, choose "System->List->Save->Local File
    (Unconverted)".
    2. Corresponding system log
    Display the system log by calling transaction SM21.
    Restrict the time interval to 10 minutes before and five minutes
    after the short dump. Then choose "System->List->Save->Local File
    (Unconverted)".
    3. If the problem occurs in a problem of your own or a modified SAP
    program: The source code of the program
    In the editor, choose "Utilities->More
    Utilities->Upload/Download->Download".
    4. Details about the conditions under which the error occurred or which
    actions and input led to the error.

    Hi Huggins,
    Maintenance of the Paging File is owned by your basis team.
    They should increase this in order for your transaction to process successfully.
    Just for your reference, in case the OS used is windows server 2003, paging file value can be checked through;
    Right click in the My Computer>properties.
    Then go to Advance tab;
    Then there should be a performance section, click the settings
    Then Advance tab again. The paging file can be seen from there.
    (and can be adjusted from there also)
    The value of the paging file in general will be dependent with the available RAM from the hardware.
    Hope this helps. Thanks a lot.
    - Jeff

  • Why files in Lightroom mobile and files in the creative cloud not the same? idea-  one place(stored date) for all application ??????

    Why files in Lightroom mobile and files in the creative cloud not the same? idea- one place(stored date) for all application ??????

    Lightroom Mobile is not a cloud storage service. You shouldn't treat it as a way of backing up your files. You are merely storing Smart Previews of your files in the cloud space, high-quality JPEGs of your files regardless of their original format on your desktop. The point is that they are there so you can continue editing them in a Lightroom-like environment even while away from your desktop/laptop computer. The files in Lightroom Mobile can only be used in Lightroom Mobile.
    This is very different from what is offered by the Creative Cloud storage, which can be used to synchronize your files between any device (that can support the individual files).
    The vast difference in how each service works and its intended use is why they are separate.

  • If i associate my apple id with another email will i lose my icloud data or i will still be able to access all my stored data with the new linked to my apple id email address?

    hi there
    if i associate my apple id with another email will i lose my icloud data or i will still be able to access all my stored data with the new linked to my apple id email address?
    i mean i am not signing up for a new account, just changing my old id primary email which is my apple id login into account.
    in other words, www.icloud.com will recognize that it is still me if i login on the site? will i be able to see there all my stored information?
    and if i change my password, does it automatically changes the @icloud.com password which should be the same as my apple id pass?
    thanks

    After opening the email it shoud of had you enter the Apple ID and password. Using certian web browser's can cause errors. You can adjust securty settings (big pain) or you use another browser. Using Firefox or Safari should do the trick.
    Let me know if using Firefox or Safari resolved it.

  • How can i get the time to appear on my stored data in notepad

    Hi all,
    I was wondering how can i get the time to appear on my stored data in notepad? I saw an example before but i forgotten which example was it.. Any ideas??
    holla
    Attachments:
    TextFile1.txt ‏3 KB

    Hi
    Im using Labview 8.2. Currently it just shows the data without the time. Im not sure what to do. It works perfectly though. I just want the time to appear on my notepad along with my data
    holla
    Attachments:
    Testing1.txt ‏1 KB
    Untitled 231_LV80.vi ‏23 KB

  • Write / store xml data in Xe and retrieve stored data using pl/sql

    Hi to all,
    i'm searching a tutorial on:
    A - how to write / store xml data in Xe and retrieve stored data using pl/sql
    I don't want to use other technologies, because i use htmldb and my best practice is with pl/sql.
    I was reading an ebook (quite old maybe) however it's about oracle 9 and it's talking about xmltype:
    1 - I don't understand if this is a user type (clob/varchar) or it's integrated in Oracle 9 however i will read it (it's chapter 3 titled Using Oracle xmldb).
    Please dont'reply here: i would be glad if someone can suggest me a good tutorial / pdf to achieve task A in Oracle XE.
    Thanx

    Thank you very much Carl,
    However my fault is that i've not tried to create the table via sql plus.
    Infact i was wrong thinking that oracle sql developer allows me to create an xmltype column via the create table tool.
    however with a ddl script like the following the table was created successfully.
    create table example1
    keyvalue varchar2(10) primary key,
    xmlcolumn xmltype
    Thank you very much for your link.
    Message was edited by:
    Marcello Nocito

  • The table for storing data for infocube and ODS

    Hi all:
        could you please tell me how to find the table for storing data for infocube and ODS?
    thank you very much!

    Hi Jingying Sony,
    To find tables for any infoprvider go to SE11.
    In database table field enter the following
    Cube -
    Has fact table and dimension table
    For customized cube - ie cube names not starting with ' 0 '
    Uncompressed Fact table - /BIC/F<infocubename>
    Compressed fact table - /BIC/E<infocubename>
    Dimension table - /BIC/D<infocubename>
    For standard cube - ie cube names  starting with ' 0 '
    Uncompressed Fact table - /BI0/F<infocubename>
    Compressed fact table - /BI0/E<infocubename>
    Dimension table - /BI0/D<infocubename>
    Click on display.
    For DSO,
    For standard DSO active table- /BI0/A<DSO name>00.
    You use 40 for new table.
    Click on display.
    For customized DSO use- /BIC/A<DSO name>00.
    An easier way is in the database table field, write the name of the cube/DSO preceeded and followed by ' * ' sign. Then press F4 . It shall give you the names of the available table for that info provider.
    Double click on the name and choose display.
    Hope this helps,
    Best regards,
    Sunmit.

  • Problem storing date in MS Access using JSP

    Hi all,
    Can anyone please help me storing date in MS Access using Java i am getting errors. I think it is probably because MS Access take "date/month". I am entering a string with date and month example
    1st October as "0110". I don't know how to enter a date in MS Access.
    Here is my code.
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    <%@page import="java.io.*"%>
    <%@page import="java.sql.*"%>
    <HTML>
    <HEAD>
    <TITLE>  </TITLE>
    </HEAD>
    <BODY>
    <%
       String emplno = request.getParameter("emplno");
       String date = request.getParameter("date");
       String proposal = request.getParameter("proposals");
       String network1 = request.getParameter("network");
       String suppassociates = request.getParameter("suppasso");
       String intmngt = request.getParameter("intmgt");
       String client[] = request.getParameterValues("client");
       String client1= request.getParameter("client1");
       String clientunit[] = request.getParameterValues("clientunit");
       String clientunit1=request.getParameter("clientunit1");
       int staffid = Integer.parseInt(emplno);
       double proposalunit=Double.parseDouble(proposal);
       double suppliersunit=Double.parseDouble(suppassociates);
       double networkunit=Double.parseDouble(network1);
       double internalmgtunit=Double.parseDouble(intmngt);
       Class.forName( "sun.jdbc.odbc.JdbcOdbcDriver" );
       Connection con = DriverManager.getConnection("jdbc:odbc:finalmp" );
       String activities= "INSERT INTO StaffActivities (StaffID,Date,ProposalUnit,NetworkingUnit,SuppliersAssociatesUnit,InternalMGTUnit) VALUES (?,?,?,?,?,?)";
       PreparedStatement pstmt = con.prepareStatement(activities);
       pstmt.setInt(1,staffid);
       pstmt.setString(2,date);
       pstmt.setDouble(3,proposalunit);
       pstmt.setDouble(4,suppliersunit);
       pstmt.setDouble(5,networkunit);
       pstmt.setDouble(6,internammgtunit);
       pstmt.executeUpdate();
       //String emplno="hello";
       //String entered_date="hello";
       //int access_date=0;
       //int user_date=0;
       if(pstmt!=null)
         pstmt.close();
       if(con!=null)
         con.close();
    %>  
    </BODY>
    </HTML>

    i hope this can help you
    public static String convertToISOFormat(Date dateTime) {
            // ISO Format: 'YYYY-MM-DD HH:MM:SS'
            String returnValue = fillLeft(String.valueOf(dateTime.getYear()+1900), 4,
                    '0')
                    + "-"
                    + fillLeft(String.valueOf(dateTime.getMonth()+1), 2, '0')
                    + "-"
                    + fillLeft(String.valueOf(dateTime.getDate()), 2, '0')
                    + " "
                    + fillLeft(String.valueOf(dateTime.getHours()), 2, '0')
                    + ":"
                    + fillLeft(String.valueOf(dateTime.getMinutes()), 2, '0')
                    + ":" + fillLeft(String.valueOf(dateTime.getSeconds()), 2, '0');
            return returnValue;
        }

  • All my stored data in Numbers are gone. What do I do?

    All my stored data in "Numbers" are gone. What do I do?

    every workbook is gone, data in one workbook is gone? Cant open a workbook, any workbook? Please be a little more specific as to the circumstances so we can try to help out.
    Thanks
    Jason

  • Having problem with storing data in array

    Hi,
    I'm having problem on storing data in array. My problem is that each time it loops, the array just keep overwrite instead save to the next index. Like at 0 the value is 123, and 1 is 234. But i having that all data capture all overwrite at 0 till the last data it still show at 0. How do i correct this problem?
    Solved!
    Go to Solution.

    How to use array to do comparison? Like Array 1 go thru array 2 to get data Loss out and build an array. Like Array 1 ,1000,1024,1048,etc before 1520 fall in between Array 2 range 1000-1500. So Freq 1000,1024,1048 etc will get Loss value as 1 and 1520 fall in between 1500-2000 will output Loss 2. and so on till the end of the list. How should do this? Need help on this.
    Array 1                                                Array 2
    Freq                                              ​     Freq   Loss
    1000                                              ​    1000      1
    1024                                              ​    1500      2
    1048                                              ​    2000      3
    1100                                              ​     :
    1200                                              ​     :
    :                                                 ​        18000
    1520
    18000

  • Why view have no stored data ?  And what is the reason view take more time

    Why view have no stored data ? And what is the reason view take more time to query ?
    what happen if a view have stored data?

    user12941450 wrote:
    I want to know the reason that why querying view is slower then querying a normal table?..Untrue.
    For example take a table with 2laks record and a view for that table.
    If i make a query like( Select name,address from table) then it works fast then select(name,address)from view..Incorrectly interpreting the results.
    A view is a SQL statement. Only difference is that the SQL statement is stored in the database's dictionary. Let's consider the following view:
    create or replace view foo_view as select * from empWhen you use the view as follows:
    select * from foo_viewOracle sees it as follows:
    select * from (select * from emp)This is no slower, or no faster, than providing the following SQL to Oracle:
    select * from empSo if you observe a difference in performance between using plain SQL versus using that same SQL via a view, there are other reasons for that difference in performance. The reason is NOT that views are slower.

  • How to reduce size of stored data?

    Does anyone know of a way to reduce the size of the stored data? The IMAP-[…]@imap.gmail.com folder in my ~/Library/Mail directory is more than twice the size of what's used on my gmail account, is it supposed to be like that?

    Do you have a lot of attachments on the messages in the mailboxes of this account? One thing that balloons storage needs is that attachments may be redundantly stored in the mailboxes. If, for example, you open Home/Library/Mail/the IMAP account folder/INBOX.imapmbox you will note that it contains two folders -- Attachments and Messages. The attachments are replicated in the Attachments folder despite also being archived with the message in the Messages folder -- this may only be true if you have selected to Keep copies of all messages and their attachments for Offline viewing, however.
    Ernie

  • Why is there always "0 bytes" in Cache in Control Panel? It never increases, yet the stored data size continues to increase.

    This is annoying. I just updated to version 19 almost a week ago and still Firefox never seeks to keep anything in "Cache". After using firefox for a few days, it crashed a couple times already and now the browser randomly freezes (to the point to where my screen on/off button wont even respond). After maybe a few seconds...things will start moving, but sluggish to where I have to shut down FF in my task manager. There us "0" bytes cache shown, but stored data is at 70MB. I went into firefox and cleared cache via the settings but that did nothing. There is still 70MB of stored data and of course it alwats shows 0 bytes cache. What's up with that? Am I going to have to "Clear Data" just to fix this and lose my bookmarks and logins tet again?

    I think it's possible that Firefox, while emptying some database files, is not compacting them, so they continue to consume the same amount of "disk" space as they did before. On desktop versions of Firefox, you can use extensions such as the following for that purpose, but I don't know whether any such thing is available for mobile. Also, it would be nice to have it built in.
    * https://addons.mozilla.org/en-us/firefox/addon/places-maintenance/
    * https://addons.mozilla.org/en-us/firefox/addon/placescleaner/
    Unfortunately, in a quick search, I do not see a general purpose Android SQLite app that will runs on Firefox profile databases without root access (unless they are on the SD card, which seems highly doubtful).

  • Storing data in structured storage

    I see everywhere that storing data in stuctured storage way is the better thing to do if we want to make fast search.
    But how can I do it.
    I only see that the default storage is clob for xmltype and we also can say "stored as clob" but how do it for store it in structured storage.
    Thank you.

    You need to register an XML Schema that defines your data. You then define the type of data your XML columns will contain using XMLSCHEMA and ELEMENT clauses..
    See the XML DB demo for more info

  • Can i access another computer's stored data on my time capsule

    can i access another computer's stored data that is on my time capsule?  My other computer died and I need to access files that are stored on the time capsule.

    http://Pondini.org/TM/FAQ.html
    See #17 in this excellent document provided by Time Capsule / Time Machine guru Pondini

  • Example storing data in the default schema with a Web Dynpro application

    Hi,
    is there any example or tutorial for storing data in the default schema with a Web Dynpro application via SQLJ or Hibernate by using the default DataSource?
    Thanks for Help,
    Dirk

    Hi,
    When you create the TAB-Strip object you should be able to set the default displayed TAB against the properties of the TAB-Strip.
    Gareth.

Maybe you are looking for

  • Reading .xml file in ABAP

    Hi All, I am trying to read a xml file which is as follows: Please suggest a way with which i can do this Thanks & Regards, Jignesh. Edited by: jignesh malde on Mar 26, 2009 2:00 PM

  • How to preserve colors when using a CMYK PDF as a texture on a 3D Layer (in a RGB document)?

    Hello! I'd like to use a CMYK PDF/Illustrator file thats coming from another designer as a label on a 3D object that I imported as a 3D Layer. The Photoshop document is in 16bit RGB mode and has the sRGB color Profile. Are these the right requirement

  • WIndows Connection to xserve from home

    Hello, We are a school that is trying to connect to our server from our house on both mac and pc. Macs work fine but pcs don't. We have an apple xserve running 10.4 that is connected to our network with an outside ip address. If someone can help it w

  • How to insert more than one row in an Oracle table in one go

    Hi All, I am working on a file-XI(BPM)-Oracle scenario. I am sending an xml file to XI via a file adapter. On the receiver end i am using a jdbc adapter to insert the row in the database. There is a transformation step within the BPM which is convert

  • Hyperion Reports - automating reports by e-mail

    <p>Hi,</p><p> </p><p>I have recently upgraded to Hyperion Reports 7.2.  I'mrunning on Essbase 6.5.42.  Our old version of HyperionReports was 2.6, and I always had problems running reports usingthe batch scheduler, so never used it.  I was hoping to