memoSequelize: FindAndCountAll の limit がエラーKeita Imatomi2017年12月10日 23:18現象Sequelize で FindAndCountAll する時、以下の条件下だとエラーになる。n:m のリレーションモデルを include するときこれとかこれとかちなみにDBはPostgreSQL対策ググると結構出てきた。subQuery: false でサブクエリを使うなとのこと。db.projects.findAndCountAll({ subQuery: false, include: [{ model: db.users, // projects と users は n:m }], limit: per_page, offset: per_page * (page - 1) })つまりどういうこと?会社のバックエンドエンジニア兼インフラエンジニアにでも聞いてみようと思う。