Fatal Error: Uncaught TypeError : mysqli_query()

Situation
Describe your problem here
When I open up openemer, i get this

"Fatal error: Uncaught TypeError: mysqli_query(): Argument #1 ($mysql) must be of type mysqli, bool given in

#0 C:\xampp\htdocs\openemr\vendor\adodb\adodb-php\drivers\adodb-mysqli.inc.php(1370): mysqli_query(false, 'SET NAMES ‘utf8…’, 0)

#1 C:\xampp\htdocs\openemr\vendor\adodb\adodb-php\adodb.inc.php(1613): ADODB_mysqli->_query('SET NAMES ‘utf8…’, false)

#2 C:\xampp\htdocs\openemr\vendor\adodb\adodb-php\drivers\adodb-mysqli.inc.php(1113): ADOConnection->_Execute('SET NAMES ‘utf8…’)

#3 C:\xampp\htdocs\openemr\library\ADODB_mysqli_log.php(60): ADODB_mysqli->execute('SET NAMES ‘utf8…’, false)

#4 C:\xampp\htdocs\openemr\library\sql.inc.php(66): ADODB_mysqli_log->ExecuteNoLog('SET NAMES ‘utf8…’)

#5 C:\xampp\htdocs\openemr\interface\globals.php(301): require_once(‘C:\xampp\htdocs…’)

#6 C:\xampp\htdocs\openemr\interface\login\login.php(41): require_once(‘C:\xampp\htdocs…’)

#7 {main} thrown in C:\xampp\htdocs\openemr\vendor\adodb\adodb-php\drivers\adodb-mysqli.inc.php on line 1370 "

OpenEMR Version
I’m using OpenEMR version 7

Browser:
I’m using: Google chrom

Operating System
I’m using: Windows 11 Pro

Search
Did you search the forum for similar questions?
Yes i did. Couldnt find a similar issue.

Logs
Did you check the logs?
Was there anything pertinent in them?
Please paste them here (surround with three backticks (```) for readability.
You can also turn on User Debugging under Administration->Globals->Logging User Debugging Options=>All

Hi ekene,
Pl check your database connection settings.

Hey Robert, thanks for replying. How do i go about doing that?

1 Like

Hi Ekene, in the openemr forlder go to >>> sites >>> default >>> sqlconf.php file
there you will see the database name, user name, passwrd, those have to be correct.

========

<?php // OpenEMR // MySQL Config global $disable_utf8_flag; $disable_utf8_flag = false; $host = 'localhost'; $port = '3306'; **$login = 'root';** **$pass = '';** **$dbase = 'openemr';** $db_encoding = 'utf8mb4'; $sqlconf = array(); global $sqlconf; $sqlconf["host"]= $host; $sqlconf["port"] = $port; $sqlconf["login"] = $login; $sqlconf["pass"] = $pass; $sqlconf["dbase"] = $dbase; $sqlconf["db_encoding"] = $db_encoding; ////////////////////////// ////////////////////////// ////////////////////////// //////DO NOT TOUCH THIS/// $config = 1; ///////////// ////////////////////////// ////////////////////////// ////////////////////////// ?>

===========
something like this you should see.