Skip to content
Advertisement

Tag: mysqli

Fatal error: Call to undefined method mysqli_result::fetch_all()

I have problems with PHP in Ubuntu 10.04. When I try use mysqli_result::fetch_all this error appears: Call to undefined method mysqli_result::fetch_all() However, it works in Windows XP. The Code: I don’t want to use fetch_assoc with a loop because I send the result to another layer for processing. I’m using PHP 5.4.4. and with php -m | grep mysql the

How do I ensure I caught all errors from MySQLi::multi_query?

The docs for multi_query say: Returns FALSE if the first statement failed. To retrieve subsequent errors from other statements you have to call mysqli_next_result() first. The docs for next_result say: Returns TRUE on success or FALSE on failure. Finally, the example posted in the docs for multi_query use the return value from next_result to determine when there are no more

Mysqli not installed?

I get the following error: Fatal error: Class ‘mysqli’ not found in my php script I have php5.3.3-7 installed and I get this when I run apt-cache show php5-mysql There is nothing about mysql at all in php info. How do I find the extention and do I have to istall it? There are many references to mysqli in my

MySQLi PHP Extension Problems

Whenever a query finishes executing, I know you should free the result. Here is a snippet of a class I built for running a simple query. Could someone tell me where I went wrong? The query, when entered properly, runs successfully. It’s just that my page doesn’t reload like it, should but it gives me these errors… … and this

Why MySQLi prepared statements?

What are the advantages of using prepared statements with MySQLi? If the only purpose is to secure the query, isn’t it better to clean the query using something like mysqli_real_escape_string instead of writing so many lines of code for each query (like prepare, bind_param, execute, close, etc.)? Answer Preparing statements is not just for code security. It helps the SQL

Advertisement