Skip to content
Advertisement

Select entries between dates in doctrine 2

I will go insane with this minimal error that I’m not getting fix. I want to select entries between two days, the examples below ilustrate all my fails:

opt 1.

JavaScript

result (0 entries):

JavaScript

opt 2

JavaScript

result (0 entries):

JavaScript

This is my table with current entries:

JavaScript

Edit 1

In order to evaluate the sql to avoid doubts, I ran this query:

JavaScript

result (3 entries):

JavaScript

So, looks like the sql is not the problem. FROM reservacion r0_ WHERE r0_.fecha > 2012 – 07

Advertisement

Answer

You can do either…

JavaScript

or…

JavaScript
User contributions licensed under: CC BY-SA
9 People found this is helpful
Advertisement