num_rows not working
Can someone tell me what I am doing wrong here?? Just trying to get a simple count and then add 1.
My table is
id - thread - message - author - date - image
I have 3 rows
1 - 1 - hello - me - 5/25/13 - me.jpg
2 - 1 - greetings - you - 5/27/13 - NULL
3 - 1 - bye - me - 5/28/13 - NULL
My results should be:
what are the values in $id and $clientID
In your table dump, you show the author field as containing string values:
Yet in your query, you are treating the field as containing a *NUMBER*:
AND author = $clientID
Which is it? If you really have a string value ("me", "you") then clearly you are never going to get a match on $clientID, which is just as clearly a number (since you don't have '...' around the value and it doesn't cause a syntax error, apparently).
EDIT: Yea, what Felgall asked. Only I'm more long-winded. <grin/>
That was the problem, I was treating it incorrectly :mad:
|All times are GMT +1. The time now is 05:13 AM.|
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.