Please watch Percona’s Senior Support Engineer Charly Batista as he presents “10 Common Mistakes (Java) Developers Make when Writing SQL”.
It's easy for Java developers (and users of other OO languages) to mix object-oriented thinking and imperative thinking. But when it comes to writing SQL the nightmare begins! Firstly, SQL is a declarative language and it has nothing to do with either OO or imperative thinking. It is relatively easy to express a condition in SQL but it is not so easy to express it optimally - and even worse to translate it to the OO paradigm. Secondly, they need to think in terms of set and relational algebra, even if unconsciously!
In this talk, we'll see the most common mistakes that developers make in OO, especially Java, when writing SQL code, and how we can avoid them.