lib/gizzard/mysql.rb in gizzard-0.2.0 vs lib/gizzard/mysql.rb in gizzard-0.3.0

- old
+ new

@@ -20,11 +20,15 @@ def order_by_id_field(ids) order_by_field(:id, ids) end - def force_index(indexes) + def use_index(indexes) from("#{table_name} USE INDEX(#{Array(indexes).join(', ')})") + end + + def force_index(indexes) + from("#{table_name} FORCE INDEX(#{Array(indexes).join(', ')})") end def lock_in_share lock('LOCK IN SHARE MODE') end