it's a great tip to install PhpMyAdmin - or phpPgAdmin for PostgresSQL -
this will only take you at most half an hour even for a newcomer.
You can then easily test queries, see any error messages and see what
result they have on tables.
In this case I'd echo out the query
echo $query = "UPDATE countertable SET CurrDate = '$ndate' WHERE ID = $id"
and try to cut-and-paste it into the query-field in PhpMyAdmin.
When you say "nothing happens" you'd probably discover that ID is a number
not matching anything _or_ that $nDate and the field are not proper date
Hope it helps!
Looking for PHP work over the net? Or would like to try to work in South
East Asia's most exiting place, Bangkok?
Then jump to http://www.u5.com/ and fill out the Developers Form.
We are urgently looking for new people in October 2002
At 15:16 2/10/2002 -0400, you wrote:
>I have the following line in a program I'm working on:
>$query = "UPDATE countertable SET CurrDate = '$ndate' WHERE ID = $id"
>$ndate is a properly formated date read from a text field on a form on the
>previous page. When I run the query using mysql_query, it returns TRUE
>each time, but the field is not updated. The only explanation I can think
>of is that there is something wrong with the date value. I've echoed it
>to the screen and it looks fine, but the query still doesn't work. Any
>Thanks in advance,
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, visit: http://www.php.net/unsub.php
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php