Welcome Guest, Not a member yet? Register   Sign In
Poll: Which database handlers would be important to you?
You do not have permission to vote in this poll.
MS-SQL
25.60%
32 25.60%
DB2
2.40%
3 2.40%
Interbase
4.00%
5 4.00%
Oracle
10.40%
13 10.40%
AWS ...
8.00%
10 8.00%
PDO
49.60%
62 49.60%
Total 125 vote(s) 100%
* You voted for this item. [Show Results]

[feature] Database Handlers
#1

Extensive database abstraction & support are built into CodeIgniter 4. The initial release supports MySQL/MariaDB, Postgres, and SQLLite. Support for other databases has been requested, but there hasn't been an outpouring of offers to help. We will slowly get to these, at least those we are familiar with, in due time.

Help provide direction to the team, by using the poll to let us know which databases are important to have handlers for. Feel free to suggest others in posts in this thread.

Database handlers current or planned:
[X] MySQL
[X] Postgres
[X] SQLLite3
[ ] What should go here?

----------------------------------------------------
This is a roadmap feature, or "epic", and a card on the roadmap board.
Component tasks will show up as issues or PRs on the development board.
We welcome comments & suggestions below.
James Parry
Project Lead
Reply
#2

I would have to say AWS driver because it seems to be taking off ( cloud Services ).
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply
#3

Oracle gets my vote. I have used CI and Oracle in my previous two jobs.
Reply
#4

I prefer PDO, as that's where all database extensions should be going eventually anyway, and all popular databases including many that aren't already have PDO drivers built into PHP. PDO is intended to provide a pretty reliable API that can port through many databases seamlessly. Is it perfect, no, but it provides a good starting foundation. This is why the most popular ORM and DBAL libraries are based on it, since it makes writing portable database code simpler. My recommendation would be to implement PDO, and once that's done, to add any other layers as development time arises to support the more niche use cases that require a database specific driver.
Reply
#5

I vote for PDO too. I assume this means I can use an Informix database?
Simpler is always better
Reply
#6

(03-13-2019, 07:45 AM)mladoux Wrote: I prefer PDO, as that's where all database extensions should be going eventually anyway, and all popular databases including many that aren't already have PDO drivers built into PHP. PDO is intended to provide a pretty reliable API that can port through many databases seamlessly. Is it perfect, no, but it provides a good starting foundation. This is why the most popular ORM and DBAL libraries are based on it, since it makes writing portable database code simpler. My recommendation would be to implement PDO, and once that's done, to add any other layers as development time arises to support the more niche use cases that require a database specific driver.

To be clear here - I believe most popular ORM and DBAL libraries use PDO because it's less work for them. CodeIgniter's database layer has always done many of the things that PDO takes care of for you. If I were starting from scratch you better believe I'd build on top of PDO and save work. At least when this conversion was started 3 years ago the non-PDO drivers of several popular engines still have more complete feature set than their PDO counterparts. I'm not sure if this is still true or not, honestly.

But just adding PDO support doesn't automatically make any database engine work with our Query Builder, Forge, etc. Those each still have to be custom tailored as they all have their own unique implementation details. PDO just abstracts the connection and basic query capabilities.
Reply
#7

My vote is by oracle I currently have several projects with this database without a driver I could not migrate them to CI4
Reply
#8

The Poll asks "Which database handlers would be important to you?" The word "handlers" could be (maybe should be) "drivers", in which case I don't think that PDO should be an option.

Consider the PHP manual's introductory description of PDO:

Quote:The PHP Data Objects (PDO) extension defines a lightweight, consistent interface for accessing databases in PHP.

PDO provides a data-access abstraction layer, which means that, regardless of which database you're using, you use the same functions to issue queries and fetch data.

That text could be used for CodeIgniter's database implementation and be 100% accurate. CodeIgniter database class(es) and PDO are both data-access abstractions.

What's the purpose of creating an abstraction into an abstraction?

PDO is not a database and the poll is about database handlers (drivers).
Reply
#9

Despite PDO not being a database, I vote for PDO. Because it's the only option to talk to a Postgres database using parameterized queries, and a stable option at that.
Reply
#10

For giggles I did a bit of Google looking for the most popular databases in 2019. This was the typical result.

  1. Oracle
  2. MySQL/MariaDB
  3. MS SQL Server
  4. PostgreSQL
  5. MongoDB
  6. DB2
  7. Microsoft Access
  8. Cassandra
  9. Redis
  10. Elastisearch

The order was pretty consistent from site to site with some minor reordering farther down the list. I tried to avoid sites that were selling some DB related product hoping for unbiased ranking. (YMMV)

Stack Overflow had a much different ranking and that one might be more relevant to this audience.

  1. MySQL
  2. PostGreSQL
  3. MS SQL Server
  4. SQLite
  5. MongoDB
  6. Redis
  7. MariaDB
  8. Oracle
  9. Elastisearch
  10. Firebase
  11. DynamoDB
  12. Cassandra
  13. Couchbase

And not one mention of PDO... because it's not a database.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB