Not sure if this applies or if it will work for you, but this is what I have
done in the past (for small inserts only).  On the "UPDATE" do a "DELETE"
from table 2 all data for that WKID, then simply do an insert.  This way you
don't have to determine which is checked or not checked. Quick and easy.

Brian

-----Original Message-----
From: Frank Liu [mailto:[email protected]] 
Sent: Friday, January 14, 2011 4:07 PM
To: cf-talk
Subject: multiple checkbox


Hello everyone.
I am new to coldfusion. Please help.
In table1, I have something like:

WKID        Name
1002        High School

In table2, I have something like:
WK            Title                Approval
1002          Math Teacher         Yes/No
1002          Scienct Teacher      Yes/No
1002          English Teacher      Yes/No

My form looks like this:
WKID:   1002
Name:   High School
                    Title                Approval
                    Math Teacher         checkbox
                    Science Teacher      checkbox
                    English Teacher      checkbox

My problem is if I only check one checkbox, but in table2, every checkbox is
checked (yes) and saved. How do I know which one is checked? if so only
checked box is saved in table2.

I see something like this:

<cfloop from = "1"  to="somethin here" index = "i">  ....
 .....
</cfloop>

But I do not know the detail. 

Thanks




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:340901
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to