The custom query language I find most annoying (possibly just because it's the one I deal with the most), is JPQL, the query language of the Java Persistence Architecture. JPA explicitly targets relational databases, so there's no obvious reason why you couldn't just use SQL. You might think the advantage of a custom query language would be that it could abstract over differences between SQL implementations, but JPQL is underspecified and just gives you the underlying database behaviour in many cases. I spent a day trying to figure out why my tests passed but the staging environment was claiming that 0 was greater than 0; turns out there was a difference in rounding behaviour between the in-memory database used for tests, and the real database, which JPA was cheerfully glossing over.