DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2005

    Need Help Storing Data in MySQL

    Hello, I am currently developing a Java Application with an SQL backbone for my senior project in college. I have this application that has 5 different JLists that pulls its values from the database. When I select values from the 5 different lists, my application adds them to another list. I want to add these selected values to a table in the database, but the problem I am running into is that I don't know the best way to do this, because in some cases there could be few selections, and in other cases there could be many selections. Does anyone have any ideas how to go about storing this data.

  2. #2
    Join Date
    Nov 2003
    Portland, OR
    Presumably the selected items are associated with a row that includes a unique key? If so, I would use a table containing that key in one column, and a selected item in another column. If user select four items from your JLists, there would be four rows with that user's ID in the selected items table. Does that make sense?
    Phil Weber

    Please post questions to the forums, where others may benefit.
    I do not offer free assistance by e-mail. Thank you!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.