Skip to content

Instantly share code, notes, and snippets.

@tenderlove
Created April 12, 2011 16:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tenderlove/915852 to your computer and use it in GitHub Desktop.
Save tenderlove/915852 to your computer and use it in GitHub Desktop.
# totally contrived example
User.select(Account[:name]).join(:accounts).where(User[:id].in(Group.where(:name => 'foo')))
@tenderlove
Copy link
Author

lol! Please take it! :-D

@ernie
Copy link

ernie commented Apr 13, 2011

@tenderlove: see activerecord-hackery/squeel@f33784217e3bbb030c21

FWIW: evaluate was a typical case of overthinking -- I didn't like stomping on Kernel#eval, even though there's no reason to care in this case. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment