1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

[ci skip] fix guides example on arbitrary SQL execution

This commit is contained in:
Konstantinos Rousis 2015-04-01 16:03:41 +02:00
parent 69881fb03b
commit 8f092302aa

View file

@ -501,7 +501,7 @@ If the helpers provided by Active Record aren't enough you can use the `execute`
method to execute arbitrary SQL:
```ruby
Product.connection.execute('UPDATE `products` SET `price`=`free` WHERE 1')
Product.connection.execute("UPDATE products SET price = 'free' WHERE 1=1")
```
For more details and examples of individual methods, check the API documentation.