When my shared hosting upgrade mysql version from 5 to 8, many of my php websites cannot be openned.

I checked php error log saw many syntax become error.

So here are the fixes of syntax :
Codeigniter : Library > common.php



Cannot combine Select, Table, Where in 1 query.
Must saperate Select, Table, Where.




Cannot write query join tables in 1 query (library/common.php).
Must saperate join tables.




Must saperate Group_By :




Must saperate Order_By :




Php pdo :
select and display data from database :
important at :
1) try
2) {$row['id']}

Join 2 tables + Group_by + Order_by :




If sql got error then check this two things :




Limit : (Must delete limit if no use limit, otherwise no result will show)




php variable in WHERE clause :




wordpress error :





Posted by Zac1987 on 28 August, 2023
| | edit post
Share On Facebook ! Share On Google Buzz ! Add To Del.icio.us ! Share On Digg ! Share On Reddit ! Share On LinkedIn ! Post To Blogger ! Share On StumbleUpon !
Share On Friend Feed ! Share On MySpace ! Share On Yahoo Buzz ! Share On Google Reader ! Google Bookmark ! Send An Email ! Blog Feed !

0 comments






Enter your email address:

Subscribe in a reader

Follow zac1987 on Twitter

Donation

If you feel my website is informative and it is useful for you, please donate some money to support me or buy me a drink. I will continues this good works. Thank you.