Doctrine_Query update with float value
- by YS-PRO
I need to increment User's balance, so I do:
Doctrine_Query::create()->from('User')->update('balance', 'balance + 0.15')->execute();
And I got an error "Unknown component alias 0". I think its because of 0.15
So how can I update (using DQL) balance without additional SELECT queries to User's table to fetch his balance, calculate new balance and do query like Doctrine_Query::create()->from('User')->update('balance', '?', $new_balance)->execute();