
i have an attribute called tags which is an array contains ["ForAbsoluteBegginers","superman", "batman", "Iron man"] inside the upload collection. now i wanted to only the the document if tags contains ForAbsoluteBegginers otherwise do not want. this is my code.
async CategoryBegginersInfo(Cateogry:string) {
try {
return await this.databases.listDocuments(
conf.appwriteDatabaseId,
conf.appwriteCollectionId,
[
Query.equal("category", Cateogry),
Query.equal("tags", ["ForAbsoluteBegginers"]),
Query.equal("status", "Approved") // Add this condition
]
);
} catch (error) {
console.error("appwrite service :: CategoryBegginersInfo :: ", error);
return false;
}
}
but it is returning me the empty document the only problem is with this line Query.equal("tags", ["ForAbsoluteBegginers"]), how to get only those document which tags includes ForAbsoluteBegginers
Recommended threads
- my database attribute stuck in processin...
when i created attributes in collection 3 of those attributes become "processing", and they are not updating, the worst thing is that i cant even delete them s...
- Is Quick Start for function creation wor...
I am trying to create a Node.js function using the Quick Start feature. It fails and tells me that it could not locate the package.json file. Isn't Quick Start ...
- Forever Processing Issue
I encountered an issue when creating attributes in the collections . if you create an attribute of type string for example and choose a size of 200 or 250 or a...
