Issue with Entity Modification and Query Results #361
Replies: 2 comments
-
|
Update: I had been thinking that |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Issue solved in: #413 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have encountered an issue with my current setup involving the entities Users and Pets (code attached). Initially, when I create a Pet for a User, everything works as expected. Queries to retrieve all Pets or to filter by Users return the correct results.
However, the problem arises when I edit a Pet. Although the edit is successful, the Pet no longer appears in the query results of the ByUserIdCollection. This discrepancy occurs because the "gsic5sk" value changes upon editing.
During creation, the
gsic5skis set to$users#pet_1. Subsequently, in the ByUserIdCollection query, it matches$users#pet_1and retrieves the record successfully. However, after an UPDATE/PATCH operation, thegsic5skchanges to$users, which disrupts the ByUserIdCollection query as it fails to find the record.Playground Link
To address this issue, I have implemented Access Patterns without the following attributes:
Is this approach correct? Is it a bug in the system, or is there a preferred method for handling this situation?
Thank you for your assistance and insights.
Beta Was this translation helpful? Give feedback.
All reactions