Skip to content
Advertisement

PHP Database writing performance PDO VS ORM

We need to insert records in mysql quite fast for the purpose of syncing it with an other database.

Which performs faster inserts. PHP PDO or some ORM (propel/doctrine)

Advertisement

Answer

Think about it for a second.

An ORM will involve creating entities and then the code will look at the mappings to figure out how to change that into SQL, etc.

Using PDO is just straight SQL statements. You give it a string of SQL and it’ll run that.

PDO wins.

User contributions licensed under: CC BY-SA
9 People found this is helpful
Advertisement