SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Hybrid View

  1. #1
    SitePoint Evangelist perpetual_dream's Avatar
    Join Date
    Nov 2005
    Location
    Jerusalem
    Posts
    542
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to efficiently Insert Parent Child Data?

    Hello,

    I am thinking about the proper way (which web controls to use and how to implement it logically) in order to allow the user to insert and display (parent and child data).... I have categories (and each category can be a parent and a child) and I want to allow the user to save add and delete and specify the parent for each category.... and I dont know what is the best way to do it?

    Thanks
    Tanzeelnet - Best arabic downloadsite
    Linux Hosting |Free Downloads |

  2. #2
    Coding and Breathing CoderMaya's Avatar
    Join Date
    Feb 2008
    Location
    Atlit, Israel
    Posts
    470
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Do it in the database:

    Table Categories:
    CategoryID, CategoryName, ParentID

    And then just fetch the results into your dataset and organize accordingly (the algorithm is really simple)


Bookmarks

Posting Permissions

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