Hi all,

I am learning to write with PHP and am stuck and need some wise souls help.
In a nutshell I need to be able to take grab a DB coulmn status and then count how many times it gets updated and output that number to a file and then have that number add to what the number was before. I have every thing working but getting the number. Here is the bit of code I have so far so it will be easier to figure what I need

function CountDefUpdates ()

UpdateICMS("UPDATE desktops SET status = \"dupend\" WHERE status = \"installed\" AND spy_policy_index = 2",$link);

$newcount = mysql_query ("SELECT



//echo $newcount;
//echo $count[0];



thanks for looking

Well this line will definitly cause you some problems:

$newcount = mysql_query ("SELECT

yes that is a problem but I was removing back to $newcount=() and didn't get it all. So if anyone can help please do. If I hard code a number in there that is what gets outputted to my text file .

thank you

$newcount isn't a number, its an sql result object and therefore you cannot add objects like that together.

I'm not entirely sure what you're trying to do. Are you're trying to keep track of how many times a column is updated?