For ActiveRecord in Rails 2.3, you can use .construct_finder_sql({})
tonypm On Saturday, 14 April 2018 15:13:15 UTC+1, Hassan Schroeder wrote: > > On Fri, Apr 13, 2018 at 10:13 PM, nyt1972 <nyt...@gmail.com <javascript:>> > wrote: > > > I want to ask Is there any tool to convet ActiveRecord 2.3.5 statement > to > > sql? > > If it's a one-time or occasional thing, just execute the statement > and grab the query SQL from your logs. > > There are also `to_sql()` methods in ActiveRecord::Relation and > ActiveRecord::ConnectionAdapters::DatabaseStatements which > (hint) you could find by searching the docs. > > HTH, > -- > Hassan Schroeder ------------------------ hassan.s...@gmail.com > <javascript:> > twitter: @hassan > Consulting Availability : Silicon Valley or remote > -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscr...@googlegroups.com. To post to this group, send email to rubyonrails-talk@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/baa4af28-9d4d-42be-b82f-473537327f1c%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.