Jump to content

Convert mysql database function to mysqli


santosh22

Recommended Posts

Hi,

I am using a grid function which creates a data grid based on the query provided. this is rich & now i find that i need to convert all functions into mysqli compatible. 

 

below are the error lines

 

            // execute the query through the "database" object
            $this->queryResult = $this->dbRefference->query($this->query);
            // get the total number of records in the result (ignoring the LIMIT)
            $this->totalRecords = $this->dbRefference->foundRows;
 
this shows error as "Notice: Undefined property: mysqli_ext::$foundRows "
 
attaching the file for reference.
 
any help is highly appreciated.
 
Thanks

class.datagrid-backup.php

you need to modify the database class to use mysqli statements, not replace the database class with an instance of the mysqli class. what was the original code for the database class? perhaps it is already using mysqli or pdo and you don't need to do anything?

Well, I have completed the changes. By doing this, I am using a single object in all of my components that access db in a php page. i m hopeful that it will improve my performance, else i will again see you guys in this forum.

 

thanks for all your help. This forum is really helpful for every question I have. 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.