不要怂,就是干,撸起袖子干!

Commit 68543550 by Mick Hansen

Merge pull request #4753 from subjectix/docs-sequelize-where

[docs] Added example for sequelize.where
2 parents fca6f724 8762758d
Showing with 5 additions and 0 deletions
...@@ -106,6 +106,11 @@ Post.update({ ...@@ -106,6 +106,11 @@ Post.update({
} }
}); });
// UPDATE post SET updatedAt = null WHERE deletedAt NOT NULL; // UPDATE post SET updatedAt = null WHERE deletedAt NOT NULL;
Post.findAll({
where: sequelize.where(sequelize.fn('char_length', sequelize.col('status')), 6)
});
// SELECT * FROM post WHERE char_length(status) = 6;
``` ```
### Operators ### Operators
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!