active_record_distinct_on icon indicating copy to clipboard operation
active_record_distinct_on copied to clipboard

undefined method 'distinct_on'

Open sam0x17 opened this issue 2 years ago • 1 comments

We are trying to use this gem within a Ruby on Jets app using active record 6.1.5.1. All attempts to get this gem to work including manually doing require 'active_record_distinct_on' seem to fail with errors like:

NoMethodError (undefined method `distinct_on' for #<Message::ActiveRecord_Relation:0x0000563c27acdc08>)

Anything I can do to get this to work?

sam0x17 avatar Apr 28 '22 20:04 sam0x17

I have not used Ruby on Jets personally.

A shot in the dark: Have you tried manually requiring the gem and calling ActiveRecordDistinctOn.install?

alecdotninja avatar Apr 28 '22 22:04 alecdotninja