I think the same thing just using the db object
$db->query("UPDATE product SET price = price + {$value}");
OR using the $db->update method
On Mon, Mar 9, 2009 at 1:58 PM, Mantasgl <[email protected]> wrote:
>
> Hi
>
> I have a form in which I write a price and i want that prices of my
> products
> could be increased by that form value.
>
> A simple query would look like "UPDATE product SET price = price +
> $formvalue['price']"
>
> This works in phpmyadmin.
>
> So how could I write such a query with zend db?
> --
> View this message in context:
> http://www.nabble.com/Zend-Db-how-to-update-rows-like-%22price%3Dprice%2BformValue-%27price%27--%22-tp22411774p22411774.html
> Sent from the Zend Framework mailing list archive at Nabble.com.
>
>
--
Vincent Gabriel.
Lead Developer, Senior Support.
Zend Certified Engineer.