> -Original Message-
> From: NIPP, SCOTT V (SBCSI) [mailto:[EMAIL PROTECTED]]
> Sent: 10 December 2002 20:02
>
> I have definitely isolated the problem. If I change
> the column name
> that the match is being performed on from 'id-sys' to
> 'id_sys' I can execute
> the query witho
> I have definitely isolated the problem. If I change the column name
> that the match is being performed on from 'id-sys' to 'id_sys' I can
execute
> the query without having to worry about quoting the column name and
> everything works. I think that I am just going to leave the column name
> ch
, SCOTT V (SBCSI); '1LT John W. Holmes'; [EMAIL PROTECTED]
Subject: Re: [PHP-DB] Update Query Help...
SCOTT,
The list's crystal ball filter is down for maintenance.
Show us the tbl schema and the debug print of $update.
Then we won't be firing blind!
=dn
> I understand th
> To: NIPP, SCOTT V (SBCSI); [EMAIL PROTECTED]
> Subject: Re: [PHP-DB] Update Query Help...
>
>
> > $tmp = $_POST['sbcuid']."-".$_POST['system'][$a];
> > $update = "UPDATE accounts SET atime='NOW()' WHERE
> > \"id-sys\&q
From: 1LT John W. Holmes [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 1:45 PM
To: NIPP, SCOTT V (SBCSI); [EMAIL PROTECTED]
Subject: Re: [PHP-DB] Update Query Help...
> $tmp = $_POST['sbcuid']."-".$_POST['system'][$a];
> $update = "UPDATE ac
SCOTT,
> I am attempting to UPDATE a table and I have having absolutely ZERO
> success. Here is the query:
> $tmp = $_POST['sbcuid']."-".$_POST['system'][$a];
> $update = "UPDATE accounts SET atime='NOW()' WHERE
> \"id-sys\"='".$tmp."'";
> echo $update;
> $result1 = mysql_query($update, $Prod) or
is it a mysql field type of datetime?
if so, you may want to use this instead
$timestamp=date("Y-m-j H:i:s");
$update = "UPDATE accounts SET atime='$timestamp' WHERE id-sys='$tmp'";
that puts the current timestamp in mysql format for entry into your table.
Cheers
Jason
-Original Message
> $tmp = $_POST['sbcuid']."-".$_POST['system'][$a];
> $update = "UPDATE accounts SET atime='NOW()' WHERE
> \"id-sys\"='".$tmp."'";
> echo $update;
> $result1 = mysql_query($update, $Prod) or die(mysql_error());
> echo mysql_affected_rows();
Try:
$update = "UPDATE accounts SET atime=NOW() WHERE id