Sequelize: Find All That Match Contains (Case Insensitive)

后端 未结 2 2081
既然无缘
既然无缘 2021-02-08 02:40

I want to use sequelize.js to query a model for records with a contains restraint. How do I do that?

This is what I have right now:

Assets
  .findAll({ l         


        
2条回答
  •  旧巷少年郎
    2021-02-08 02:54

    If you are using sequlize better to use [Op.iLike]: `%${request.body.query}%` and you can forget about the sequlize functions.

提交回复
热议问题