Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

sequelize count all

Project.count().then(c => {
  console.log("There are " + c + " projects!")
})

Project.count({ where: {'id': {[Op.gt]: 25}} }).then(c => {
  console.log("There are " + c + " projects with an id greater than 25.")
})
Source by sequelize.org #
 
PREVIOUS NEXT
Tagged: #sequelize #count
ADD COMMENT
Topic
Name
3+9 =