1. 05 9月, 2011 2 次提交
  2. 04 9月, 2011 1 次提交
  3. 01 9月, 2011 1 次提交
  4. 29 8月, 2011 1 次提交
  5. 21 8月, 2011 2 次提交
  6. 14 8月, 2011 5 次提交
  7. 09 8月, 2011 1 次提交
    • J
      Make it the responsibility of the connection to hold onto an ARel visitor for... · 7db90aa7
      Jon Leighton 提交于
      Make it the responsibility of the connection to hold onto an ARel visitor for generating SQL. This improves the code architecture generally, and solves some problems with marshalling. Adapter authors please take note: you now need to define an Adapter.visitor_for method, but it degrades gracefully with a deprecation warning for now.
      7db90aa7
  8. 28 7月, 2011 2 次提交
  9. 27 7月, 2011 1 次提交
  10. 26 7月, 2011 2 次提交
  11. 24 7月, 2011 1 次提交
  12. 20 7月, 2011 1 次提交
  13. 19 7月, 2011 1 次提交
  14. 09 7月, 2011 1 次提交
  15. 07 7月, 2011 2 次提交
  16. 05 7月, 2011 1 次提交
  17. 29 6月, 2011 2 次提交
  18. 28 6月, 2011 1 次提交
  19. 24 6月, 2011 1 次提交
  20. 23 6月, 2011 1 次提交
  21. 22 6月, 2011 1 次提交
    • C
      Stop find_in_batches using the records after yielding. · 96be08de
      Caius Durling 提交于
      Currently if the code that calls .find_in_batches modifies the yielded array in place then .find_in_batches can enter an infinite loop searching with ruby object ids in the database instead of the primary key of records in the database. This happens because it naively assumes the yielded array hasn't been modified before calling #id on the last object in the array. And ruby (1.8 at least) alias' #id to #object_id so an integer is still returned no matter what the last object is.
      
      By moving finding the #id of the last object before yielding the array it means the calling code can do whatever it wants to the array in terms of modifying it in place, and .find_in_batches doesn't care.
      96be08de
  22. 21 6月, 2011 1 次提交
  23. 02 6月, 2011 1 次提交
    • B
      Fix issue #1272 · 1e43bd9f
      Brian Mathiyakom 提交于
      Set reverse_order_value when asked to reverse_order().
      Do the actual reversal in build_arel.
      1e43bd9f
  24. 01 6月, 2011 1 次提交
  25. 25 5月, 2011 1 次提交
  26. 24 5月, 2011 1 次提交
  27. 21 5月, 2011 1 次提交
  28. 20 5月, 2011 1 次提交
  29. 12 5月, 2011 1 次提交
  30. 09 5月, 2011 1 次提交
    • N
      Fix for #371 · 92c10760
      Nick Howard 提交于
      if a query contains a limit or an offset, ActiveRecord::FinderMethods#find_last had inconsistent behavior.
      
      If the records were loaded, it returned the last record in the cached list.
      If they were not, it reversed the order of the query and changed the limit to one.
      If the earlier limit was less than the total matching the query in the db,
      it would return a different record than if the records had been cached.
      
      This commit changes find_last so that it loads the records when getting the
      last record on a query containing a limit or an offset, which makes the behavior consistent.
      92c10760