-
Notifications
You must be signed in to change notification settings - Fork 80
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
Rearranging all models #17
Comments
Hello @Subhash23jan , Go for it |
Hello @Subhash23jan , A single document in MongoDB is limited to 16MB. This limit may be reached if a user has a lot of orders or items in their cart, and also You will need to locate and make any necessary updates to each user document that contains an order or cart item, such as when a product's price changes which makes it more complex . @Trisha-tech We can use this strategy if you are not concerned about these possible problems with your application. |
Hello @SidharthaPaidi , Go for it |
@SidharthaPaidi |
@Trisha-tech
when user deletes, then cart should be deleted, but since user and cart are different collections, we can't do this
we can have order and cart list in the user schema
whenever user deletes, then his order and cart details would be deleted. From this, we can reduce the database storage, it's easy to get details without co mplex queries and we can reduce times as well.
if this idea works for your application
Could you please assign this work?
The text was updated successfully, but these errors were encountered: