3 ms·
After mostly relying on ORMs for years, I wanted to brush up on SQL, so I wrote this... https://github.com/amorphid/learn_sql_ruby https://github.com/amorphid/
by amorphid 8y ago
After mostly relying on ORMs for years, I wanted to brush up on SQL, so I wrote this...
https://github.com/amorphid/learn_sql_ruby https://github.com/amorphid/learn_sql_ruby
Basically I just used the pg gem for Ruby to execute a bunch of raw SQL commands and wrote tests to check to see if the output was correct. It taught me a bunch in just a few days!
- bitexploder 8y agoORM is much easier when you know what is going on and can dove into a query plan. I have noticed most devs that struggle with ORM and or performance tend to just not understand basic RDBMS/SQL stuff. Indexes, joins, how to tell ORM to prefetch, reviewing query plans when the performance matters.