Not sure how to classify this one ?

Results 1 to 2 of 2

Thread: Not sure how to classify this one ?

  1. #1
    Dan Carter Guest

    Default Not sure how to classify this one ?

    I currently have an AddRecord ASP page, which executes 2 SQL statements to Insert data from 1 form into 2 separate tables.<BR>Now when I add a record using the above method I also need to Insert the primary key and a record for every user in my Users table to *another* table (there are only 5-6 users)<BR><BR>e.g. the new table will hold 5-6 records for the ID from the form that was just added, each one with the same ID, but different user ID.<BR><BR>Hope this makes sense.<BR><BR>How can I do this ?<BR>Do I need to use a Loop ???<BR>I am stumped......<BR><BR>Please help.<BR><BR><BR>Thanks

  2. #2
    Join Date
    Dec 1969

    Default RE: Not sure how to classify this one ?

    &#062; Do I need to use a Loop ???<BR><BR>Yep. You can only insert one record at a time, so loop away.<BR><BR>(You can alter or delete multiple records, but not add them. Hmmm...I guess you could create a stored procedure that would add multiple records in a loop, but that&#039s just moving the problem to another level, not really changing the solution.)<BR><BR>

Posting Permissions

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