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

pulldata should support local entities #6443

Open
seadowg opened this issue Oct 9, 2024 · 3 comments · Fixed by #6451
Open

pulldata should support local entities #6443

seadowg opened this issue Oct 9, 2024 · 3 comments · Fixed by #6451
Assignees
Milestone

Comments

@seadowg
Copy link
Member

seadowg commented Oct 9, 2024

Currently, using pulldata with an entity list will not work as expected as the data queried will be the entity list CSV rather than the local entities so data entities may not exist or may be out of date. pulldata should work correctly in these cases and use the local entities.

For the moment, search does not need to support local entities.

Notes

pulldata is implemented as a custom function (ExternalDataHandlerPull). As we're most likely going to be removing the current implementation (and just treat pulldata as sugar for optimised queries) we should create a new custom function that wraps the current implementation and just expands pulldata to a "normal" filter expression if the filtered instance is an entity list. For example, pulldata('fruits', 'name', 'name_key', 'mango') should just be treated as instance('fruits')/root/item[name_key='mango'][1]/name.

@seadowg
Copy link
Member Author

seadowg commented Oct 9, 2024

@lognaturel is my mapping of pulldata to a normal filter correct here?

@lognaturel
Copy link
Member

The last name_key should be name but otherwise that's right. Good call on the [1], that's an important one.

@lognaturel
Copy link
Member

Some review comments to address at #6451 (review)

@lognaturel lognaturel reopened this Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: not ready
Development

Successfully merging a pull request may close this issue.

2 participants