PG::UndefinedColumn: ERROR: column "expired_at" does not exist LINE 1: ...."site_id" = 1 AND "articles"."enabled" = $2 AND (expired_at... ^ : SELECT "articles".* FROM "articles" WHERE "articles"."user_id" = $1 AND "articles"."site_id" = 1 AND "articles"."enabled" = $2 AND (expired_at IS NULL OR expired_at > '2017-08-19 05:28:10.126727') AND (published_at <= '2017-08-19 05:28:10.126815') ORDER BY "articles"."published_at" DESC LIMIT 15 OFFSET 0