rails admin column does not exist
问题 I'm getting a column does not exist when editing a user in rails admin. The relationship between sales and users is user has_many :sales, and sale belongs_to buyer and another belongs_to for seller, written out like belongs_to :seller, :class_name=>User, :foreign_key=>:seller_id ActionView::Template::Error (PG::Error: ERROR: column sales.user_id does not exist LINE 1: SELECT "sales".* FROM "sales" WHERE "sales"."user_id" = 14 ^ : SELECT "sales".* FROM "sales" WHERE "sales"."user_id" = 14): 1: