用云函数sequelize查找腾讯云mysql问题,数字可以查找,文字就不行
var User = sequelize.define('book', {
book_tsmc: {
type: Sequelize.STRING,
field: 'book_tsmc' // Will result in an attribute that is firstName when user facing but first_name in the database
},
book_txm: {
type: Sequelize.STRING,
field: 'book_txm' // Will result in an attribute that is firstName when user facing but first_name in the database
},
book_lx: {
type: Sequelize.STRING,
field: 'book_txm' // Will result in an attribute that is firstName when user facing but first_name in the database
},
}, {
timestamps: false,
freezeTableName: true, // Model tableName will be the same as the model name
charset: 'utf8',
collate: 'utf8_unicode_ci'
});
cloud.init()
exports.main = async (event, context) => {
return await User.findAll({
where: {
book_txm: '33060002'
},
limit: 10
})
}
数字查找正常返回记录,用文字就不行,哪位大神知道怎么回事吗