I know that I can OR values with
TypeScript
database.listDocuments(
queries: [
Query.equal("attribute", [value1, value2]),
]
)
And I know I can AND attributes like so
TypeScript
database.listDocuments(
queries: [
Query.equal("attribute1", [value1]),
Query.equal("attribute2", [value2]),
]
)
Is there a way to also OR attributes? Something like
TypeScript
database.listDocuments(
queries: [
Query.equal(["attribute1", "attribute2"], value1),
]
)
Or am I forced to do this ine two seperate queries?
TL;DR
The user is asking if there is a way to check multiple attributes at once in a database query using Appwrite. Currently, Appwrite does not support passing an array in the field value. The user suggests starting a feature request on the Appwrite GitHub page. The user then provides examples of how to use `OR` and `AND` conditions separately. However, the user is asking if there is a way to `OR` attributes together in a single query. It is not possible to `OR` attributes together in Appwrite, so the user is forced to use two separate queries.As of now Appwrite don't support passing array in the field value
That's sounds like something that can benefit many peoples. You can start a feature request in Github https://github.com/appwrite/appwrite/issues
Recommended threads
- HUGE OUTRAGE IN APPWRITE, I CANNOT ACCES...
I have 2k users trying to access, sending me messages. What am I supposed to do? Please solve this asap.
- All my apps are not opening now
All my apps are not opening now 200+ apps are not opening plz fast
- Failed to generate functions SSL
```appwrite-worker-certificates | Cannot renew domain (functions.domain.com) on attempt no. 9 certificate: Failed to verify domain DNS records. appwrite-worker...