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 1086393
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T22:48:27+00:00 2026-05-16T22:48:27+00:00

I try new table structure for our new eccomemrce website like WordPress tables. But

  • 0

I try new table structure for our new eccomemrce website like WordPress tables. But I am not sure whether it’s really good idea for performance.

We’ve just 2 tables for products and other contents (such us pages, attachments, or even orders). Their ordinary fields kept first table (such as ID, title,date), but their special fields kept second table (such as price, quantity, options, features). That means all special fields of a product are in the just one table.

We thought if we use cache cleverly, it doesn’t matter.

What do you think?

(Please if you really have good experience, just answer this question)

Table Structure:

contents: (TABLE 1)

CONTENT_ID   TITLE  DESCRIPTION  DATE

content_fields: (TABLE 2)

FIELD_ID   CONTENT_ID    KEY_NAME    VALUE

Example (Get product that has 1 ID and its shipping is FREE):

SELECT *  FROM `contents` as c LEFT JOIN `content_fields` as cf ON  c.content_id = cf.content_id WHERE c.content_id = 1 AND  cf.key_name = 'free_shipping' AND cf.value = 'yes'
  • 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-16T22:48:27+00:00Added an answer on May 16, 2026 at 10:48 pm

    I have really bad experience with this model, do I qualify? 😉

    This kind of abstraction can make sense, but up to a point – you have to weigh the similarities and differences between various objects: for example, grouping CMS templates and e-mail templates together makes sense (as many important parts would be shared), grouping CMS pages and delivery orders doesn’t make much sense (as they only have a few, relatively unimportant, shared pieces of data).

    The decision “what is similar enough”, will be subjective; but it needs to be done. Otherwise, you may fall into the trap of “everything is an object”.

    True Story: one company I’ve worked with had a similar idea: everything (a CMS page, an order, a customer, an e-mail) is an Entity and is stored in the entities table; properties specific to the object go to entity_properties and entity_property_values tables. It was a Huge Unholy Mess (TM), as the objects had almost nothing in common, so 99% of the data was stored as entity_properties and/or various references to other Entities. (In other words, abstracting everything to a common base object has left us with many useless base objects).

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

Sidebar

Related Questions

I'm pretty proficient in PHP, but want to try something new. I'm also know
I am trying to get twitter updates like this: try { $doc = new
Good day, I try to start new Activity from another. But it always crashed.
I'm not quite sure stackoverflow is a place for such a general question, but
When an exception is thrown or encountered: void ThrowException() { try { throw new
I try to use new Function() in a calculator and I find it does
my code is static { try { sessionFactory = new AnnotationConfiguration().configure().buildSessionFactory(); } catch (Throwable
If I want to try out something new in Ruby or Javascript, I love
I am creating date using following code try { newdatetime = new DateTime(2012, 2,
I have the following code to connect to MongoDB: try { $m = new

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.