Check out v4 of the Fauna CLI
v4 of the Fauna CLI is now in beta. The new version introduces enhancements to the developer experience, including an improved authentication workflow. To get started, check out the CLI v4 quick start. |
Credential.where()
Get the Set of accessible Credential in the database.
Description
Each credential in a Fauna database is represented by a Credential
document. Credential.where()
gets the Set
of accessible documents that
match the predicate function.
Parameters
Parameter | Type | Required | Description |
---|---|---|---|
pred |
Yes |
An anonymous function that compares values in each |
Return value
Type | Description |
---|---|
Set representing the documents that match the predicate function. If this
method is the last value in a query, the method returns the first page of the
|
Examples
Credential.where(.document == Customer.byId("111"))
{
data: [
{
id: "412654807560487424",
coll: Credential,
ts: Time("2099-08-11T04:25:08.950Z"),
document: Customer("111")
}
]
}
Is this article helpful?
Tell Fauna how the article can be improved:
Visit Fauna's forums
or email docs@fauna.com
Thank you for your feedback!