Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Multiple Insert to table

Posted on 2003-11-26
4
Medium Priority
?
320 Views
Last Modified: 2010-04-25
I have developed a training registration web app. I am tryiing to add attendance tracking to it. The problem I have is when the trainer selects the class, they get a listing (detail page) of all the students who have registered. I added a field called (attended - yes \ no) to my table and add a check box to the listing. When I submit the form, all the students update 1 record.

How do I do submit multiplte records to the database. I saw something that showed how to update multiplte table (with 1 record) utlizing commands, but I have not used this function yet.
0
Comment
Question by:jkatz2
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 23

Expert Comment

by:Saqib Khan
ID: 9834901
jkatz2 I need more Details about your Questions.
What you trying to say this You want to update MULTIPLE Tables by doing one Click or Multiple Fields within one Table?

if Multiple Tables Then run your Code Line BY Line to do whatever you want, if Updating one Table and Multiple Fields then all you have to do this Update/Modify your Sql Statement.

Let me know what you need.
0
 

Author Comment

by:jkatz2
ID: 9835329
I need to update 1 table with several records. I have a listing of customers Fname \ Lname \ ect, and a field (attended) that needs to be updated for each record. There can be up to 20 records showing?

0
 
LVL 15

Expert Comment

by:gladxml
ID: 9982965
0
 
LVL 2

Accepted Solution

by:
Jim M earned 600 total points
ID: 10112568
jkatz,

I think I know what you're getting at...but your terminology  was confusing me. You aren't submitting (i.e. inserting) multiple records to the db, you're updating multiple records.

There is a good, relevant tutorial at:

http://www.newmanzone.com/recipes/recipe.asp?LinkID=1

Those he's talking about batch deletes, the concept is exactly the same for you, except you're going to be updating.

The general idea is that each checkbox needs to be unique (i.e. the registants memberID or whatever you're using). Then you have to do a little hand coding to loop in the update statement

Here's an exaple of what your checkbox code should be like:

<input name="MM_recordId" type="checkbox" id="MM_recordId" value="<%= rsGetMembers.Fields.Item("MemberID").Value %>">

Basically your form will have all the folks - each in a separate row - with a checkbox for registered/not registered beside each. You go down the list, check the ones you want, then submit the form.


There is very little hand coding required to do this, and you'll find this is very easy to do!

Any questions, just ask. Hope this helps!

-g8tor23
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For those who don't know, Adobe Dreamweaver is a popular commercial web editor that enables you to design, build and manage complex websites. The editor is a WYSIWYG (What You See Is What You Get) web editor, which means that you can create your web…
Adobe Dreamweaver CS5 is a WYSIWYG web page editor that has advanced HTML, CSS, and Javascript rendering functionality and is probably the most well-known HTML editor available. Much of Dreamweaver's appeal centers around the Design View interfac…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question