Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-14 Thread Chris
Stan wrote: OK. If I change the test to "if(mysql_num_rows($thisRow) < 1)" it does what I want. I guess if I want to understand why False was returned originally (just after I created the database) I need to start over. According to the docs mysql_query only returns false if there's an error.

Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-14 Thread Stan
OK. If I change the test to "if(mysql_num_rows($thisRow) < 1)" it does what I want. I guess if I want to understand why False was returned originally (just after I created the database) I need to start over. Do I have 4 possible conditions here: 1) the mysql_query() function fails and I get a PH

Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-14 Thread Stan
Yes. I deleted all records. Prior to the DELETE, if I did a SELECT with specific criteria (WHERE p.pictureFile = "some valid content"), and those criteria were not met, mysql_query() returned False ... and, conversely, if those criteria were met, mysql_query() returned "a resource" against which I

Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-13 Thread Chris
Stan wrote: I did a "DELETE FROM picture" where "picture" is a table in my database. Because this deletes all your records - so doing a select afterwards will find nothing. Afterward, this piece of code does not generate an error -- try {