Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

HTML forms /MySQL

Status
Not open for further replies.

frankalbers

Programmer
Jan 3, 2002
3
0
0
DE
Hello there and Happy New Year!

I'm trying to write some code in PHP that should put several sets of data from one HTML form into a MySQL database. It works pefectly fine when I do it with one set but I do not know how to do it with multiple ones. My code for the single set entry:

$query = "INSERT INTO bank VALUES (NULL, '$date','$cheq' ,'$supplier' ,'$purchaser' , '$int_invoice_no', '$invoice_no')";

And my unsuccessful one on the multiple sets:

while ($in>0 OR $out>0)
{
$query = "INSERT INTO bank VALUES (NULL, '$date','$cheq' ,'$supplier' ,'$purchaser' , '$int_invoice_no', '$invoice_no', '$in', '$out')";

}

If anybody ever had this kind of problem bevore please help me out!
Regards,
Frank
 
Can describe more? What is your $in and $out for? How many set of form you have? ------------------
Freedom is a Right
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top