Drupal 7 is a filled with a lot of things that fill you with delight and despair all at the same time. And EnityFieldQuery is one of them. It seems to do everything and yet, when refuses to bend to your will.
Recently, in one of my projects, the use case was that we had to display the number of PDF files the currently logged in user generated in the current month. A simple thing if I were using SQL. But I wanted so badly to do this using EntityFieldQuery. And here’s what I ended up with:
Voila! I truly ♥ EntityFieldQuery.
There’s a thread on Drupal.org of more such examples. Do have a look. I too have cross-posted this example there. Also, the api.drupal.org page on EntityFieldQuery has some fantastic documentation—be sure to check it out.