Skip to main content

Nested Records



An awesome nested set implementation for Active Record

awesome_nested_set 3,716,932 Downloads Last release

collectiveidea/awesome_nested_set Last commit


Ancestry allows the records of a ActiveRecord model to be organized in a tree structure, using a single, intuitively formatted database column. It exposes all the standard tree structure relations (ancestors, parent, root, children, siblings, descendants) and all of them can be fetched in a single sql query. Additional features are named_scopes, integrity checking, integrity restoration, arrangement of (sub)tree into hashes and different strategies for dealing with orphaned records.

ancestry 3,055,027 Downloads Last release

stefankroes/ancestry Last commit


Easily and efficiently make your ActiveRecord model support hierarchies

closure_tree 675,087 Downloads Last release

mceachen/closure_tree Last commit


A gem that adds simple support for organizing ActiveRecord models into parent–children relationships.

acts_as_tree 1,966,965 Downloads Last release


Subscribe to the newsletter

Join 31,353+ developers who get early access to new screencasts, articles, guides, updates, and more.

    By clicking this button, you agree to the GoRails Terms of Service and Privacy Policy.

    More of a social being? We're also on Twitter and YouTube.