MySQL or MySQLi

Mihai B.

Well-known member
Joined
Apr 19, 2016
Messages
191
Best answers
0
Ratings
17
Points
18
#1
In my config file of my website cms, it decaled this variable

Code:
$config['Database']['dbtype'] = 'mysqli';
and on old version

Code:
$config['Database']['dbtype'] = 'mysql';
Which should I use? why?

Can you tell me what is the difference between mysqli and mysql? which one is right for you?


thanks
Mihai
 

HostBastic

Well-known member
Joined
Nov 17, 2016
Messages
320
Best answers
1
Ratings
40 2
Points
28
#2
MySQLi or MySQL Improved and somtimes refered as MySQL improved extension is a relational database driver that is used with PHP. MySQLi is a replacement for the mysql functions, with object-oriented and procedural versions, it supports prepared statements.
Which one is right for you, that depends on what you are trying to achive, however both will be able to use MySQL from PHP.
 
Joined
Mar 15, 2017
Messages
59
Best answers
0
Ratings
3
Points
0
#3
MySQL is the old database and Improved driver. MySQLi takes advantage of the newer features of MySQL 5.
MySQLi is the OOP version of MySQL extension. In the end, MySQLi and MySQL accomplish the same thing: they are extensions for interacting with MySQL from PHP.
 
Joined
Mar 17, 2017
Messages
60
Best answers
0
Ratings
2
Points
8
#4
Hello,
As far I know MySQLi Extension (or simply known as MySQL Improved or MySQLi) is a relational database driver that is used mainly in the PHP programming language. It provides an interface to the already founded MySQL databases. It is quite literally an improved version of its predecessor, MySQL, which was simply a means to manage databases over servers.
 

overcast

Well-known member
Joined
Jun 27, 2017
Messages
88
Best answers
0
Ratings
2
Points
0
#5
You should migrate to Mysqli as soon as possible. If you choose to use old verison then in future you may have to update code for the php 7. In php 7 onwards you don't have much backward compatibility support. So use MySQLi and PDO.
 

24x7serverman

Well-known member
Joined
Jul 25, 2017
Messages
651
Best answers
2
Ratings
72 6
Points
28
#6
MySQLi is improved version of MySQL. It offers more security and supports various features like prepared statement, both procedural and object-oriented interface. It has debugging feature too. Extension directories for MSQL is /etc/mysql and for MySQLi is /etc/mysqli.
 
Latest Threads
Replies
2
Views
19
Replies
4
Views
57
Replies
4
Views
55
Replies
5
Views
51

Latest postsNew threads

Latest Hosting OffersNew Reviews

Sponsors

Latest Blog ArticlesMost Viewed Threads

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top