update query syntax
Posted: Wed Mar 02, 2005 9:19 pm
hope anyone can help me on the syntax...
i will update a single row where the conditions are :
field 1 and field 2 have values and field 3 is empty i tried this code:
$query = "UPDATE tbl SET field3='$Today' WHERE userName = '$user' and data3 ='NULL'";
userName is field 2 and data3 should have the value of $today which is initially empty
i tried the one above but it doesnt insert the data... thanks so much!
i will update a single row where the conditions are :
field 1 and field 2 have values and field 3 is empty i tried this code:
$query = "UPDATE tbl SET field3='$Today' WHERE userName = '$user' and data3 ='NULL'";
userName is field 2 and data3 should have the value of $today which is initially empty
i tried the one above but it doesnt insert the data... thanks so much!