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

  • Home
  • SEARCH
  • 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 470409
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T23:52:55+00:00 2026-05-12T23:52:55+00:00

Firstly this site is based on guests who are interested in selling their items

  • 0

Firstly this site is based on guests who are interested in selling their items to the site owner, so this isn’t auction based like Ebay.

Visitors basically would enter in details of an item ( tech gadget ) they’d like to sell, including condition, are given a quote on how much the item is worth, then fill in address info so the owner ships them a box/label so they can ship their item to the owner. If the owner is content with the condition, the visitor gets paid either by check or Paypal.

So going by this, I would need to have some sort of orders ( or is it more semantically correct to call it a transaction, or something else? ) table in which I track every single ‘order’ that the customer makes.

The items accepted are preselected, so there are only a few specific models/manufacturers so I was going to make an items table along with manufacturers and populate that like so:

items table:

item_id item_name                 manufacturer    item_category_type
1       iPhone 32gb 3GS           1               1
2       Sidekick 3                2               1

manufacturers table:

id  manufacturer_name
1   Apple
2   T-Mobile

There are also multiple types of items, item categories:

item_categories:

id  item_category
1   phone
2   ipod
3   computer (pc,laptop)

orders:

id user_id item_id  estimated_price  ac_adapter   battery  manuals  cables
1  5       2        250             1             1        1        1

users:

id user_email    user_address      user_city   user_state user_zip user_country 
1  foo@bar.com   302 Kingston Ave  Manhattan   New York   11111    United States

The price will be generated based on conditions, so for example whether or not a phone has an ac adapter, battery, manuals, cables, I indicated those in the orders table but I’m not quite sure if I should even store that in a table.

Question 1: Is the way I’m storing the ac_adapter, battery, manuals column in the orders table the correct way of doing this? I’d appreciate any tips.


The site will also have an admin area where the admin can look at all the orders, and there will be a user area where the user can look at his orders, in addition theres a request to have emails stored there too.

So after a user makes an ‘order’ then I’ll have to add an entry to the users table if the user isn’t already registered, and add an entry to the orders table, along with emailing the user a copy of this and emailing the site owner a copy of the order information. And next comes the part I’m confused about, storing emails – is it as simple as just creating an emails table, and possibly a second table relating the order transactions with the emails? And just mail the email_body to both the site owner and the user? Here’s the schema I’m thinking of:

emails table:

id    order_number    email_title                 email_body ( TEXT column? )
1     1               sitename.com - Order #1     ( stuff )

Question #2: And for the email body, the way I’d generate that is join all the columns dictated by the order number, and just make an HTML table out of all that, include the date.. is this usually how email storing in databases is done?

I apologize in advance as this is a very loaded question, hoping someone with enough experience in these types of sites can assist. Thanks.

  • 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-05-12T23:52:55+00:00Added an answer on May 12, 2026 at 11:52 pm

    Is the way I’m storing the ac_adapter, battery, manuals column in the orders table the correct way of doing this?

    No, because ac_adapter/battery/manuals are attributes of the item – not the order. If an order is returned, and a subsequent person orders the item – you’ve duplicated the data vs a single entry in the items table.

    And for the email body, the way I’d generate that is join all the columns dictated by the order number, and just make an HTML table out of all that, include the date.. is this usually how email storing in databases is done?

    Some webclients don’t handle HTML formatted email well, this is generally left to user choice between text and HTML.

    I wouldn’t store the email at all – there’s no value from an auto-generated email your system created. I can understand storing the template in the db, but email isn’t a reliable contact method either so the most I’d do would be to have a column to indicate msg status (be it boolean/bit or foreign key). Besides, why store what’ll alsob be stored in your email sent items folder?

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

Sidebar

Related Questions

Firstly, this is going to sound like homework, but it ain't. Just a problem
Firstly, This might seem like a long question. I don't think it is... The
Short story. This site was created by a friend of mine, who did not
Firstly just a big Thanks to everyone on this site, I am using it
My first post - firstly have to say that this site is great -
firstly I don't which is the correct stackExchange site to post this question if
Ok, firstly this is not about forms this is about consistent layout as a
Firstly sorry if this is a common question but I couldn't find anything on
ok so i have code that fundementally has this structure: firstly a main div
Firstly: I am totally a newbie for this kind of work. I have a

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.