what the diffeernce between mysql and mysqli........what should i use...
The MySQLi extension, like the PDO extension, provides an object oriented interface with support for prepared statements and other features available in MySQL 4.1 and above. As such, I suggest that you use the MySQLi extension or PDO extension unless you have no choice except to use the MySQL extension.
ok now for this problem, i will write your code and test again......let me see..i will post back if i get a problem
Yep. The mysql_error() will give a more detailed error message that may hint what is the problem.
EDIT:
I just wrote your code and this is the error,
PROCEDURE myDB.getSubs can't return a result set in the given context
hmm... but when you tried it in the mysql command line it worked.
I have never had a reason to use stored procedures, so I am not sure how to diagnose the problem. One possibility is that the MySQL extension does not allow you to call stored procedures. Another possibility is that if your stored procedure has more than one SQL statement, this causes problems since mysql_query() is designed to only execute one SQL statement at a time. If this is the case, then multi_query() from the MySQLi extension might be a fix. Another possible fix would then be to use the PDO extension, possibly with the PDOStatement::nextRowset().