Open micahbowerbank opened 5 years ago
I ran into Sequelize deprecation warnings for all these operators with $
. Maybe they deprecated it in the newest version. Which one are you using? Can you try to follow this comment https://github.com/sequelize/sequelize/issues/8417#issuecomment-337884136 as fix?
I got the same error as @micahbowerbank with Sequelize 4.41.2. The solution he gave works.
Thanks for confirming this @crashspringfield I will take this issue into for the next book edition.
In case someone else runs into this issue, please write a comment here and how you worked around the issue :)
https://sequelize.org/master/manual/querying.html#where
imported Op module from sequelize and replaced $in with [Op.in]
So, use [Sequelize.Op.in]: keys
instead of $in: keys
. It works!
Same Issue but it works when updating to @micahbowerbank solution.
When I use the following from the example
I get the following error
if I change it to the following then everything works
I don't know if this is because I have a newer package or something. But it took me hours to figure it out, so I figured I would share with everyone else