Answers for "sequelize or"

0

sequelize or

Post.findAll({
  where: {
    [Op.or]: [{authorId: 12}, {authorId: 13}]
  }
});
// SELECT * FROM post WHERE authorId = 12 OR authorId = 13;

Post.findAll({
  where: {
    authorId: {
      [Op.or]: [12, 13]
    }
  }
});
// SELECT * FROM post WHERE authorId = 12 OR authorId = 13;
Posted by: Guest on September-03-2021
0

SEQUELIZE OR

"SELECT * FROM Student WHERE LastName='Doe' OR FirstName in ("John","Jane") OR Age>18"
Posted by: Guest on December-18-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language