-
Notifications
You must be signed in to change notification settings - Fork 4.4k
🚀 Feature: Add feature for getting data between specific date and time? #6340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
There is a query method named Related issue: #5650 I could not use const queries: any[] = [];
8000
// Query for users with birthdates between the selected min and max ages
if (filterData?.minAge && filterData?.maxAge) {
const minDate = new Date();
minDate.setFullYear(minDate.getFullYear() - filterData?.maxAge);
const maxDate = new Date();
maxDate.setFullYear(maxDate.getFullYear() - filterData?.minAge);
queries.push(Query.greaterThanEqual('birthdate', minDate.toISOString()));
queries.push(Query.lessThanEqual('birthdate', maxDate.toISOString()));
}
...
this.appwrite.listDocuments(
environment.appwrite.USERS_COLLECTION,
queries
); |
What if I want to fetch posts between 1 week, 1 month or a year? |
@SMARTMICROWORLD, dates are ISO 8601 formatted strings in UTC timezone (like |
Hey,Is this issue still open.I like to work on it. |
🔖 Feature description
I was trying to fetch data between time like this:
Query.greaterThanEqual('date_time', specifiDate), Query.lessThanEqual('date_time', new Date()),
but getting error like:
Error: [AppwriteException: Server Error]
Please add this feature as fast as possible please.
🎤 Pitch
Firebase offers this feature like:
.where('date_time', '>=', specifiDate) .where('date_time', '<=', new Date())
It will be very useful for users to find any items or posts between or before/after an specific time
Thanks
👀 Have you spent some time to check if this issue has been raised before?
🏢 Have you read the Code of Conduct?
The text was updated successfully, but these errors were encountered: