[TYPO3-mvc] No Query-Result with two DateTime comparisons
Daniel Völkel
d.voelkel at medienwuerfel.de
Thu Aug 28 10:35:42 CEST 2014
Hi guys,
I'm having a problem with a query in Extbase 6.2. I want to check if a DateTime-field is set between two dates, but no result is returned.
return $query->matching(
$query->logicalAnd(
$query->greaterThan('ankunftstag', $today),
$query->lessThan('ankunftstag', $enddate)
)
)->execute();
If leave just compare to one date, the result is correct ... and identical in both comparisons, so the date is between those dates used for comparison
return $query->matching(
$query->greaterThan('ankunftstag', $today),
)->execute();
return $query->matching(
$query->lessThan('ankunftstag', $enddate)
)->execute();
Do you have any ideas what is wrong?
Kind regards,
Dan
More information about the TYPO3-project-typo3v4mvc
mailing list