SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Zealot
    Join Date
    Oct 2007
    Posts
    117
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Forms and inserting to DB

    Hi all

    When designing a very big form lets say it has 10 stages would you
    A) insert and update the DB at each different stages
    B) Save all values to sessions and do loads of inserts at the end
    C) do something else that I havent thought of.

    From what I can see

    A) is good but if people don't complete the form fully then your DB is left with possible data in it which is rubbish and meaningless. Alongside this if the user flicks between stages you will also need an update function as well as an insert function

    B) is good however if the session times out then all the information the user has entered has been lost


    Cheers

  2. #2
    SitePoint Zealot
    Join Date
    May 2009
    Location
    usa
    Posts
    113
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I suggest you to directly run update query, if the table is empty, it will insert automatically, this saves your time.

  3. #3
    SitePoint Zealot
    Join Date
    Oct 2007
    Posts
    117
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry I don't get what you mean by

    directly run update query
    Please could you explain further


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
  •