Ticket #894 (closed defect: fixed)
SQL BETWEEN Condition broken
| Reported by: | crem0r | Owned by: | romanb |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Component: | Query/Hydration | Version: | 2.0-DEV |
| Severity: | Keywords: | ||
| Cc: | Has Test: | no | |
| Status: | Pending Core Response | Has Patch: | no |
Description
The second question mark is missing in the SQL output and the resulting query.
$result = Doctrine_Query::create()
->from('Day d')
->where('d.date BETWEEN ? AND ?', array($beginDate, $endDate))
->getDql();
var_dump($result);
Output:
string ' FROM Day d WHERE d.date BETWEEN ? AND ?' (length=40)
$result = Doctrine_Query::create()
->from('Day d')
->where('d.date BETWEEN ? AND ?', array($beginDate, $endDate))
->getSql();
var_dump($result);
Ouput:
string 'SELECT t.id AS t__id, t.date AS t__date, t.begintime AS t__begintime, t.endtime AS t__endtime, t.workingtime AS t__workingtime, t.comment AS t__comment, t.user_id AS t__user_id FROM test_arbeitszeitkonto_days t WHERE (t.date BETWEEN ? AND )' (length=240)
==> The second question mark is missing in the SQL output and the resulting query.
Change History
Note: See
TracTickets for help on using
tickets.