Hacker News new | ask | show | jobs
by ta2234234242 815 days ago
Are they worse? The popularity of them has exploded like programming languages from the 80's to now.

One might say that if SQL was so great there would be no ORMs -- because there would be no need.

The ORMs, if anything, are a symptom of the larger problem that is SQL.

1 comments

> One might say that if SQL was so great there would be no ORMs

It's not like the ORMs exist without SQL. Their primary purpose is to provide a consistent interface between different flavors of SQL so the application developer doesn't need to care what database they're using.

For example, delimiting object names in Mysql uses ` and in Postgres uses ". The ORM will ostensibly have different adapters which take care of these differences without changing the application code.

Not even that works painlessly. You commonly run into incompatibilities so an ORM won't necessarily make your code database agnostic.
It lessens the pain, still. It's rare that you'd use common ORM methods and run into something that's supported for one RDBMS and not another. Doing stuff that's less common and, of course, writing raw SQL will still be pain points but they'll be fewer than if one was doing everything in raw SQL.
> It's not like the ORMs exist without SQL.

That's because TINA: There is No Alternative.