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

[@loopback/sequelize] contains & match (extendedOperators) are not working #10272

Closed
vaibhavkumar-sf opened this issue Dec 22, 2023 · 1 comment · Fixed by #10284
Closed

[@loopback/sequelize] contains & match (extendedOperators) are not working #10272

vaibhavkumar-sf opened this issue Dec 22, 2023 · 1 comment · Fixed by #10284

Comments

@vaibhavkumar-sf
Copy link
Contributor

vaibhavkumar-sf commented Dec 22, 2023

Describe the bug

image
image
image
image

Also for ExtendedOperator (Match),
There is no equivalent operator for "match" in sequelize.

We're using it like :

/localhost:4005/app-facade/tenants/f5408ba4-521f-4f96-fe87-bf0e6092ea16/patients/encounters?encountersType=both&filter={"limit":50,"where":{"and":[],"fullName":{"match":"%jiya:*&%"}}}

25%22%7D%7D%7D&encountersType=both Completed in 27ms
[2023-12-22T08:50:39.993Z] error :: App_Log -> Request GET /tenants/f5408ba4-521f-4f96-fe87-bf0e6092ea16/patients/encounters/count?filter=%7B%22where%22%3A%7B%22and%22%3A%5B%5D%2C%22fullName%22%3A%7B%22match%22%3A%22%25jiya%3A%2A%26%25%22%7D%7D%7D&encountersType=both errored out. Error :: {} Error: There is no equivalent operator for "match" in sequelize.
Request GET /tenants/f5408ba4-521f-4f96-fe87-bf0e6092ea16/patients/encounters/count?filter=%7B%22where%22%3A%7B%22and%22%3A%5B%5D%2C%22fullName%22%3A%7B%22match%22%3A%22%25jiya%3A%2A%26%25%22%7D%7D%7D&encountersType=both failed with status code 500. Error: There is no equivalent operator for "match" in sequelize.

Logs

image

Additional information

No response

Reproduction

the issue is obvious and the provided information is enough to understand the problem.

@vaibhavkumar-sf vaibhavkumar-sf changed the title [@loopback/sequelize] contains & match are not working in where builder, these were working fine with Juggler [@loopback/sequelize] contains & match (extendedOperators) are not working in where builder, these were working fine with Juggler Dec 22, 2023
@vaibhavkumar-sf vaibhavkumar-sf changed the title [@loopback/sequelize] contains & match (extendedOperators) are not working in where builder, these were working fine with Juggler [@loopback/sequelize] contains & match (extendedOperators) are not working Dec 22, 2023
@samarpanB
Copy link
Contributor

Its a feature not yet implemented in sequelize extension.

yeshamavani added a commit to yeshamavani/loopback-next that referenced this issue Jan 5, 2024
postgres supports extended operators but missing in sequelize

fix loopbackio#10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
yeshamavani added a commit to yeshamavani/loopback-next that referenced this issue Jan 8, 2024
added test cases for same

fix loopbackio#10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
yeshamavani added a commit to yeshamavani/loopback-next that referenced this issue Jan 11, 2024
added test cases

fix loopbackio#10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
yeshamavani added a commit to yeshamavani/loopback-next that referenced this issue Jan 12, 2024
fix loopbackio#10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
samarpanB pushed a commit that referenced this issue Jan 18, 2024
postgres supports extended operators but missing in sequelize

fix #10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
samarpanB pushed a commit that referenced this issue Jan 18, 2024
added test cases for same

fix #10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
samarpanB pushed a commit that referenced this issue Jan 18, 2024
added test cases

fix #10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
samarpanB pushed a commit that referenced this issue Jan 18, 2024
fix #10272

Signed-off-by: Yesha Mavani <yesha.mavani@sourcefuse.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants