News for hackers. Stuff that matters.
Re:Frameworks Don't Make Much Sense by melloclello on Friday March 11, 2016 @01:21AM (#11264968)
> My particular bugbear is working with people who refuse to learn SQL as if it's some arcane bit of weirdness on a par with machine code. They've only ever used ORMs and have no idea how to actually talk to their data. /rant

Lol this is me. People who write their SQL from scratch confuse me, I'm like, just use the ORM and then everything's consistent! :P

Re:Frameworks Don't Make Much Sense by spotman on Friday March 11, 2016 @01:26AM (#11264978)
The real trick is to have a deep understanding of SQL before you use an ORM so that you know exactly what you are asking the ORM to ask the database to do.

Otherwise you will never be able to really understand what is going on and will not be able to optimize a complex app that needs to be performant at scale.

Learning both has its advantages and I think an ORM can indeed speed up development, most especially for the prototyping phase.

Re:Frameworks Don't Make Much Sense by sanderjd on Friday March 11, 2016 @01:32AM (#11265000)
Learning about the relational model and its mapping in SQL is a really major level-up that you should really consider getting under your belt!

I used to do a lot of hiring of Rails developers, and always believed (though admittedly not scientifically enough) that the best differentiator between "sorta productive" and "capable of fully independent work" was an understanding of how AR maps to SQL and the ability to know when (and how best) to drop down into writing queries directly.

Re:Frameworks Don't Make Much Sense by ericd on Friday March 11, 2016 @01:59AM (#11265102)
You might want to look at some of the SQL that your ORM is generating for your important queries... Because a lot of times, odds are it's much, much less efficient than it could be.

I've seen ActiveRecord create some head scratchers.

Re:Frameworks Don't Make Much Sense by seivan on Friday March 11, 2016 @02:19AM (#11265181)
There is a big difference between ActiveRecord pre and post Arel. Give it another go if you haven't seen Arel in action.
Re:Frameworks Don't Make Much Sense by ChrisDutrow on Friday March 11, 2016 @02:52AM (#11265297)
A developer who doesn't understand SQL could be a little dangerous because they might not understand data structures and big-O concepts (sets, hash tables, etc..). I don't think someone needs to be a wizard with the syntax, but they need to understand what the database is doing. Otherwise they could write something that won't handle load under real world use.
Re:Frameworks Don't Make Much Sense by douche on Friday March 11, 2016 @08:46AM (#11266532)
One of the things I like about the .NET Linq-to-SQL and EF ORMs is that it's pretty easy to plug into them and get them to dump the actual SQL that they are executing.

Still, you really need to have a good handle on the difference between operations that build up the query, without executing it, and those that pull the data back from the database. Also understanding what code constructs that the ORM is capable of translating into SQL statements.

Re:Frameworks Don't Make Much Sense by ChrisDutrow on Friday March 11, 2016 @01:38PM (#11268593)
.NET is actually the framework that gave me such a bad taste for frameworks. It's important to note that my experience with it is from around 2010-2012 though so it could have gotten much better since.

The ORM in particular would sometimes cause me to write very inefficient queries. If I understood the ORM better, I probably could have avoided this, but I found it much easier to write a data layer that ran SQL queries directly and supplied the other layers with simple JSON-like objects.

Re:Frameworks Don't Make Much Sense by marcus_holmes on Friday March 11, 2016 @06:15PM (#11270264)
me too. EF was what caused me to (finally) dump the entire .Net ecosystem and start learning again from scratch with Linux.
Re:Frameworks Don't Make Much Sense by ChrisDutrow on Saturday March 12, 2016 @03:30PM (#11274394)
Yeah, most of the projects I've been working on lately wouldn't be possible with a licensed operating system. For me, working with linux is very difficult, but the capability far outweighs the difficulty. I don't catch on easily to concepts, commands, and multiple steps of such an advanced tool.
Re:Frameworks Don't Make Much Sense by nissimk on Friday March 11, 2016 @08:05AM (#11266346)
Don't trade consistency for power. If you know sql, you can answer questions about your data without writing a program, by just executing queries in a database UI. This ad-hoc querying is far more powerful than any other debugging technique for many classes of problems.