Ok, I found out why the UPDATE on the table wasn't working. I wasn't
giving
the command a 'fake' value for the ID column. Ok here is the senario.
I have a form which dumps data to cols 1,2,3,5 in a table (thats
good). I have another script which runs a loop on the data into another
form where I
"Gerard Samuel" <[EMAIL PROTECTED]> wrote:
> OK it worked, but now I have to figure out why its only updating the
> first row.
> Tyler Longren wrote:
> > yeah...jibberish. Should be this:
> > UPDATE mpn_asklee SET reply='$Reply[$i]', Post='$post[$i]' WHERE
> > ID='$counts'"
If each row ha
Thanks for telling me that I was talking jibberish :)
OK it worked, but now I have to figure out why its only updating the
first row.
Ill be back if I cant figure it out.
Thanks all
Tyler Longren wrote:
> yeah...jibberish. Should be this:
> UPDATE mpn_asklee SET reply='$Reply[$i]', Post='
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
try this syntax:
UPDATE table SET col=value, col2=value2 ... WHERE ID=$id;
> -Original Message-
> From: Gerard Samuel [mailto:[EMAIL PROTECTED]]
> Sent: Monday, August 13, 2001 3:20 PM
> To: PHP
> Subject: [PHP] UPDATE s
On 13-Aug-2001 Gerard Samuel wrote:
> I have a database with 5 columns and cols 1,2,3 & 5 are filled. I want
> to insert into 4 and change 5. Could I use an UPDATE command to do
> this.. Here is what I have ==>
>
> $query = "UPDATE mpn_asklee (Reply, Post) VALUES
> ('$Reply[$i]', '$
yeah...jibberish. Should be this:
UPDATE mpn_asklee SET reply='$Reply[$i]', Post='$post[$i]' WHERE
ID='$counts'"
On Mon, 13 Aug 2001 15:20:17 -0400
Gerard Samuel <[EMAIL PROTECTED]> wrote:
> I have a database with 5 columns and cols 1,2,3 & 5 are filled. I want
> to insert into 4 and change
I have a database with 5 columns and cols 1,2,3 & 5 are filled. I want
to insert into 4 and change 5. Could I use an UPDATE command to do
this.. Here is what I have ==>
$query = "UPDATE mpn_asklee (Reply, Post) VALUES
('$Reply[$i]', '$post[$i]') WHERE ID = '$counts'";
$result = mysql
7 matches
Mail list logo