SQl num_rows problem


Posted on 16th Feb 2014 07:03 pm by admin

when i try to count rows from an SQL select i get an warning

Code: [Select]$countviews = mysql_query("SELECT * FROM viewed WHERE sfw = '0' AND cookieid = $id");
$num_rows_viewed = mysql_num_rows($countviews);
Code: [Select]Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in ******.php on line 58
anybody an idea why this is?

No comments posted yet

Your Answer:

Login to answer
282 Like 31 Dislike
Previous forums Next forums
Other forums

smart reading from a text file
Hello there fellow coders, i was wondering if one of you wouldnt mind helping me with this problem i

delete comma
HI,

How to delete "," at the end of the string.
Code: $match = 2009/02/03/a2corr

Is this Safe or Unsafe?
Hi i made a few pages with lots of peoples help now i just want to know if they are safe or not can

Rss feed question
Hi

My blog and my website are different. Am i able to take my rss feed
from my blog and p

SCO Unix
I know this might not be the place to ask, but, can anyone tell me if SCO Unix comes with PHP built

Using two $_POST Function / Switch () statements, second does not work.
Hi all. I’m new to php and am having a problem getting $_POST Function / switch () to work. I

Count number of records in all the tables with a querry URGENT PLEASE...
I downloaded ORACLE 9I DATA DUMP into my comp. There are number of tables. I need to find out the

ClientScript.RegisterClientScriptBlock Issue
This is what I haveview plaincopy to clipboardprint?Protected Sub posrback_Click(ByVal sender As Obj

Set Categories
I am creating a submission form for somebody to come in and submit products. These products are sep

Logging and nologging bulk insert
Hi,

oracle version: 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash