Sha256: 337fdd90b61c2c41dfd5b98d6a042319105c2f599eebbbc77b766923f70322b6
Contents?: true
Size: 331 Bytes
Versions: 7
Compression:
Stored size: 331 Bytes
Contents
require 'active_record/querying' module ActiveRecord::Querying delegate :with, :ranked, to: :all def from_cte(name, expression) table = Arel::Table.new(name) cte_proxy = CTEProxy.new(name, self) relation = ActiveRecord::Relation.new cte_proxy, cte_proxy.arel_table relation.with name => expression end end
Version data entries
7 entries across 7 versions & 1 rubygems