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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T07:02:20+00:00 2026-05-16T07:02:20+00:00

I need to be able to store something like this: where the green is

  • 0

I need to be able to store something like this:
Structure

where the green is a template type, the gray is a field container type, and the white is field. (That being, a field has a label and some text, both mediumtext for simplicity; and a field container can store other field containers or text, and a template is a top-level field.)

Now, let’s say I want to allow users to create any number of these structures, but it is unlikely to be more than say 10. And, of course, we need to be able to link data to it.

This is all to be able to store in a database an associative array that looks for the above like, in pseudo code:

my_template = {
  page_info => { description => 'hello!!!' },
  id => 0,
  content => { background_url => '12121.jpg', text => ...
}

Having an easy way to add a field to all data using the template when the template changes (say, we add a keywords to page_info) would be a big plus.

I can’t figure this out at all, thanks a lot!

  • 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-16T07:02:21+00:00Added an answer on May 16, 2026 at 7:02 am

    There are several different ways to store heirarchical data structures (trees) in MySQL. You can for example choose:

    • Adjacency list
    • Nested sets
    • Path enumeration
    • Closure table

    See Bill Karwin’s presentation for more details on the pros and cons of each.

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

Sidebar

Related Questions

I need to create a configuration section, that is able to store key-value pairs
I'm trying to parse strings that represent source code, something like this: [code lang=html]
I have a mysql table that looks something like this: Row 1: 'visitor_input_id' =>
I need a Dictionary like object that can store multiple entries with the same
Users of the website need to able to store images in their area ,
I need to be able to store a date (year/month/day) with no time component.
I need to be able to store the current height and width of a
I have a large amount of data I need to store, and be able
Need to be able to pull Magento products into an external template. Need to
Summary: I want to know if it is possible to do something like this:

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.