Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7906197
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T10:49:32+00:00 2026-06-03T10:49:32+00:00

I got one order table, when user come to the store they could purchase

  • 0

I got one order table, when user come to the store they could purchase more than one item for example. may i know what is the best practices to perform such record action ? is that each item order one row in order table or mix all into one row in order table ?

Let say, Customer A purchase 3 items from store. then will be 3 row in order table ? or 1 row in order table with all details and separate order with delimiter ?

My designed structure is like this::

tblOrder
    OrderID (Primary Key)
    UserID
    TotalPrice

tblOrderItem
    OrderItemID (Primary Key)
    OrderID (Referencing tblOrder)
    Quantity
    ItemID (Referencing tblItem)
    TotalPrice 

Is this correct ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T10:49:34+00:00Added an answer on June 3, 2026 at 10:49 am

    I will suggest you to maintain 3 rows, because it will be easy for you to maintain further.

    Updated:

    @SLim, The structure is looking perfect for the situation now. You will proceed further with this.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hello I have got this php order by annotations on my one to many
I got one implementation of read/write locks which is below. Notice that in the
I got one problem at my exam for subject Principal of Programming Language. I
I got one main search field always visible at the site and a login
i got one page from curl which contain <?xml version=1.0 encoding=UTF-8?> <ipinfo xmlns=http://data.quova.com/1 xmlns:xs=http://www.w3.org/2001/XMLSchema-instance>
I've got one really big .java class file that has a lot of members.
I've got one Posgresql database (I'm the owner) and I'd like to drop it
I've got one function checkEvery15Seconds that runs every 15 seconds. It checks to see
I have got one weird issue. I am working on an asp .net mvc
I've got one if, and one else in my script. But I need something

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.