Skip to content

Instantly share code, notes, and snippets.

@ProGM
ProGM / arel_cheatsheet_on_steroids.md
Last active June 14, 2024 02:40
Arel cheatsheet on Steroids

Arel Cheatsheet on Steroids

A (more) complete cheatsheet for Arel, including NamedFunction functions, raw SQL and window functions.

Tables

posts = Arel::Table.new(:posts)
posts = Post.arel_table # ActiveRecord

Table alias