Remix.run Logo
hparadiz an hour ago

Some of us have been working with php for 22 years at this point and frankly I think Doctrine is the best ORM period.

nullable_bool an hour ago | parent [-]

What makes it so good? Genuinely curious

hparadiz an hour ago | parent [-]

It uses a DTO style mapping system and central factory EntityManager making unit testing a breeze. Model definitions let you map database primitives directly from the models. It will automagically build you the table on first use and it's capable of moving data from one engine to another engine on the fly. Migrations are built in and it's capable of generating migrations directly from changes to a model. It's smart about SQL multi saves (transactions), joins for relationships, views, and a bunch of other database features that most ORMs don't even bother to be even aware of let alone implement. It's basically an enterprise level ORM. Functionally it works like ActiveRecord but under the hood it's very different.

winrid an hour ago | parent [-]

Have you used Django's ORM?

hparadiz an hour ago | parent [-]

The first time I heard the name Django was like 15 years ago in college so I'm sure I've used it by hosting some project for one reason or another over the years. Python is just not my go to. Also I maintain my own framework in PHP entirely so that's what I pull off the shelf when I wanna do CRUD.