news.volyx.in

What ORMs have taught me: just learn SQL (2014) (wozniak.ca)

795 points by BerislavLopac · 2584 days ago · 634 comments on HN

Article summary

The article discusses the benefits of learning SQL over relying on Object-Relational Mappers (ORMs). Although the article itself is not available, the comments suggest that knowing SQL can save time and effort in the long run. SQL is a domain-specific language for working with relational data, and using it directly can be more efficient than using an ORM. Many commenters agree that learning SQL is essential, even if one uses an ORM.

Main themes

  • SQL vs ORMs
  • Database querying
  • Object-relational mapping
  • Learning SQL
  • Database performance

What commenters say

  • Learning SQL is more beneficial than relying on ORMs because it allows for more efficient and flexible database querying.
  • ORMs can be useful for basic queries, but SQL is necessary for complex queries and performance optimization.
  • Using an ORM does not preclude the need to learn SQL, as understanding SQL is essential for using ORMs efficiently.
  • Some developers prefer to use ORMs for simplicity and ease of use, while others prefer to write raw SQL for more control and performance.
  • The choice between using an ORM or writing raw SQL depends on the specific needs of the project and the developer's goals.
  • SQL composition can be achieved through subqueries or other query building techniques, making it a viable alternative to ORMs for complex queries.
  • Understanding the differences between active record and data mapper patterns is important for choosing the right approach to object-relational mapping.