In MySql i have a primary key field id, when i do select * from users where id='12p' it brings the value of row 12.
Please how do I go about this.
Updated Nodejs sample
const { User } = require('models')
User.findOne({where:{id:'12p'}}).then(user => console.log(user))
'12p'is auto casted to a int by MySQL.. Thats why you should NOT ever use single qoutes on a int datatype. Note other database systems will give a error when using single qoutes on a int datatype.