Error in phpMyAdmin when joining tables (TypeError: htmlspecialchars(): Argument #1 ($string) must be of type string, null given)

553 views Asked by At

I have been trying to join two tables where the (on) condition column may contain null value. I kept getting this following php error in php myadmin:

TypeError: htmlspecialchars(): Argument #1 ($string) must be of type string, 
null given in C:\xampp\phpMyAdmin\libraries\classes\Display\Results.php on line 2012

After a lot of investigtation, it turned out that the phpMyAdmin version (5.1.1) was not compatible with the PHP version (8.0.13)

Following this link to upgrade the phpMyAdmin to latest (5.2.0) the error did not appear again and I was able to run my query successfully.

Updating phpmyadmin in xampp server

Also here is my query just FYI

SELECT * from table uc 
LEFT JOIN table u 
on u.id <=> uc.user_id
1

There are 1 answers

0
Sarah Tammam On

After a lot of investigtation, it turned out that the phpMyAdmin version (5.1.1) was not compatible with the PHP version (8.0.13)

Following this link to upgrade the phpMyAdmin to latest (5.2.0) the error did not appear again and I was able to run my query successfully.

Updating phpmyadmin in xampp server