Is there a good way to do "exists"

Im using pg. Is there a clean way to do a query analagous to something like
await db.user.exists({where: {x: y} });
Was this page helpful?