Skip to content
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

Use id instead of foreign key to delete all documents in a collection #45

Closed
jaeyson opened this issue Aug 6, 2024 · 0 comments
Closed
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@jaeyson
Copy link
Owner

jaeyson commented Aug 6, 2024

#33 (review)

Using the id from document is much better than using foreign key for clearing up all documents in a collection.

Update:

To delete all documents in a collection, you can use a filter that matches all documents in your collection. For eg, if you have an int32 field called popularity in your documents, you can use filter_by=popularity:>0 to delete all documents.

Another discussion: https://threads.typesense.org/t/deleting-typesense-documents-with-specific-field-using-filter-by-/2J3912e

I'll open this issue if Typesense added a wildcard for filter_by in id

@jaeyson jaeyson added the documentation Improvements or additions to documentation label Aug 6, 2024
@jaeyson jaeyson self-assigned this Aug 6, 2024
@jaeyson jaeyson moved this to In Progress in ExTypesense Aug 6, 2024
@jaeyson jaeyson linked a pull request Aug 6, 2024 that will close this issue
@jaeyson jaeyson moved this from In Progress to Todo in ExTypesense Aug 6, 2024
@jaeyson jaeyson closed this as not planned Won't fix, can't repro, duplicate, stale Aug 6, 2024
@github-project-automation github-project-automation bot moved this from Todo to Done in ExTypesense Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant