I want to show specific month with year data according to $ceatedAt property , i am unable to do it , how will i do this ?
TL;DR
User is having trouble with an Appwrite query involving the $createdAt property. They posted their code which included a limit, order, greater than, and not equal operators. They are specifically asking how to filter data based on a specific month and year using the $createdAt property.
Another user suggests converting the date to an ISO 8601 string in UTC before executing the code.
The original user responds that their code now works after making the suggested changes.
Solution: The user needed to format the date as an ISO 8601 string in UTC before executing the query.TypeScript
databaseID,
collectionId,
[
Query.limit(50),
Query.orderDesc("$createdAt"),
Query.greaterThan("$createdAt",date).
Query.notEqual("status","failed"),
]
);```
this code i have written , but its not working at all
Did you format date as an iso 8601 string in UTC?
After converting , my code works , thanks
[SOLVED] Appwrite Query Help with $createdAt property
Recommended threads
- Custom API domain is unreachable
Earlier my custom api domain was working fine. Now it seems to be offline without a trace a few hours later. I didn't change anything, all the relevant DNS reco...
- "Invalid console fingerprint" when unpau...
I've tried logging out and logging back in, still can't figure out why this is happening.
- Inviting members while SMTP is disabled ...
Issue: https://github.com/appwrite/console/issues/3125 PR: https://github.com/appwrite/console/pull/3126