Re: [PHP] Moving from mysql functions to mysqli or PDO - which is best?

[email protected] (Matijn Woudt)
Newsgroups php.general
Message-ID <CAC_gtuNk133EBJjykodou6Z1QGPnP7QDwBxGKB3qVtZe5mYJjQ@mail.gmail.com>
On Sat, May 18, 2013 at 8:09 PM, dealTek <[email protected]> wrote:

> Hi folks,
>
> [post newbie abilities] - I'm attempting to move away from PHP mysql
> functions to something newer, either mysqli or PDO.
>
> I have read various things about them, but I'm curious at this point which
> would be best to learn for the present and future. I'm usually working on
> small to medium size projects.
>
> I understand that PDO has an extra abstraction layer so it can work with /
> convert to other databases like oracle and others fairly easily, but some
> have said that PDO can be a bit slower the MySQLi?
>
> So I would really like to hear opinions on the best choices of either
> MySQLi or PDO.
>
> Also I'm also trying to learn OOP, so I'm looking for a very good working
> PDO and/or mysqli database class - to get started with, that has all the
> basic needs like UPDATE - INSERT - DELETE - QUERY etc. That would be very
> helpful.
>
> Thanks in advance for your opinions!
>
>
Hi,

Probably some people will say PDO, others will say MySQLi, in general it
doesn't really matter, and I think you have named the biggest differences
in your mail.
So if you're going to stick with MySQL anyway, you can take advantage of
the speed with MySQLi.

What class are you looking for?
MySQLi can be used as a class, and PDO is a class too?

- Matijn
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.