> Now the problem is it only inserts one row into the table, when there should be
> more than one row inserted.
Of course it does, you have to enclose the insert statement into
your for loop.
--
Herzlich
Werner Stuerenburg
_
ISIS Ve
Hi,
I was missing two single quotes in the $val line after $id[$i] and before
songname : Here is the corrected code
$vals .=", ('$id[$i]', '$songname[$i]', '$rating[$i]', '$video[$i]',
'$album_id[$i]',
'$movie[$i]')";
Now the problem is it only inserts one row into the table, when there s
Hi,
if you have 6 colums, you are inserting only 5 in table
INSERT INTO songs VALUES (' 1, blah', ' ***', ' 45', ' 2', ' ')
[1th ] [2nd] [3rd] [4th] [5th]
i think that first apostrophe is shifted to left side
should be:
INSERT INTO songs VALUES (1, 'blah', ' **
I am trying to insert an array of rows or values from a PHP form into a
MySQL database. There are six columns in the table songs: id, songname,
rating, video, album_id, movie.
Here is what I get when I submit the form
Add songs for Record Array
INSERT INTO songs VALUES (' 1, blah', ' ***', ' 45',