Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder
    Join Date
    May 2006
    Posts
    123
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Basic mySQL theory (simple question, but hard to categorize)

    Hi everyone. I'm trying to create a database, and although I have no problem working with mySQL, there are a few "basic theory" issues I've never dealt with before.

    Basically, all I really want to know is the "standard practice" when creating databases to be used with websites. For instance, assuming that each "article" of a website has multiple paragraphs, would that mean that each paragraph would have it's own table cell?

    For example, I'm envisioning creating a "text" table with all the text to be used for the site with the article name to be used as the key, i.e.:

    ARTICLENAME(key) TEXT1 TEXT2 TEXT3 TEXT4 TEXT5

    exampleTitle exText... exText... exText... exText... exText...


    If this were the case, then how would headings work? I was thinking that you would have a "headings" table, but then you would have to specify a number for how many paragraphs would go under each heading (assuming the amount of text per heading varies per article).

    Of course I could just go ahead and CREATE my database in this way, but it somehow seemed kind of like re-inventing the wheel, and for all I know there is a completely standard (and ideal) way of doing this when it comes to something as common as articles for a website.



    I don't necessarily need a concrete answer to my question, but does anyone out there know a good site that I can study for answers to these kinds of questions about database standards and practices?

    Thanks a bunch.

  • #2
    Super Moderator guelphdad's Avatar
    Join Date
    Mar 2006
    Location
    St. Catharines, Ontario Canada
    Posts
    2,631
    Thanks
    4
    Thanked 147 Times in 138 Posts
    You would create the entire document and save it in one single row in your table. You would not break it up at all.

  • #3
    Regular Coder
    Join Date
    May 2006
    Posts
    123
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Gotcha!

    I actually found "textile" and figured out all about it...

    Thanks a bunch.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •