I have a full version of PHP Grid (version 1.5.2). When I changed my PHP Grid config file use to mysqli, the call to a stored procedure in my custom 'on_insert' function stopped working. It is set up like this:
$query = "CALL sp_insert_stored_proc('$field1', '$field2', '$field3')";
mysql_query($query) or die (mysql_error);
(the real parameters for '$fieldx' above are set up by using the
$data["params"]["fieldname"] calls)
Should something else be changed in the function to make this insert work once I begin using mysqli?
Thank you.
And one additional piece of information, it does not display an error message, it just does not update the row.
To see the message, you need to set:
phpgrid_error( mysql_error() );
You can also see message from ajax response. Use firebug to see the ajax post response.
https://phpgrid.desk.com/customer/portal/articles/926266
Abu,
I got this error:
Access denied for user ''@'localhost' (using password: NO)
I created a second connection file that is exactly the same as the 'mysql' connection file in every respect except for the 'db_type' parameter (mysqli v. mysql).
Thank you.
Hi,
I am unable to generate this issue.
Please share the code for review (can use pastebin.com)
Mysqli code sample:
http://phpgrid.org/demo/demos/loading/db-layer-mysqli.phps
Same works with config type 'mysql'