The count
function gets the number of matching rows
let c = Customer[true].count() //total number of customers
let c2 = Customer[name == 'smith'].count() //number of customers with name 'smith'
The exists
function returns a boolean indicating whether any matching
records exist.
let c = Customer[true].exists() //any customers?
let c2 = Customer[name == 'smith'].exists() //any customers with name 'smith'?