标签: javascript mysql sql node.js sequelize.js
我有以下代码,它以{attack_id: value}格式返回行,但是我需要返回所有列,而不仅仅是attack_id。我该如何使用续集?
{attack_id: value}
attack_id
const { count, rows } = await attacks.findAndCountAll({ attributes: [ [sequelize.fn('DISTINCT', sequelize.col('attack_id')), 'attack_id'], ], });