The comparison between PHP and frameworks isn't valid. Writing PHP on a framework probably abstracts away SQL too, just like writing CGI in Python gives you lower-level control.
Yes, when I write a web app, I don't want to be stuck with extra code that abstracts away the database into a less-efficient object/class and forces me to break the convention of the framework to write the code that I need.
I suppose it's fine when many of then newer programmers don't even know or understand what's going on underneath anyway...
It's not really apples and oranges - writing a website in raw Ruby is not a very feasible or popular option, whereas writing a website in raw PHP is. It is valid to compare writing a site in PHP and writing a website in Rails. It is also valid to compare writing one in Cake vs. RoR, as well as Cake vs. raw PHP (or a custom PHP framework, which is what raw PHP inevitably becomes in a sufficiently large project).