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

NodeBase query by entityId? #45

Closed
jansorg opened this issue Apr 25, 2018 · 2 comments
Closed

NodeBase query by entityId? #45

jansorg opened this issue Apr 25, 2018 · 2 comments

Comments

@jansorg
Copy link

jansorg commented Apr 25, 2018

Thanks for adding entityId / xdId!

Is there a way to create a NodeBase query to locate by entityId? This would be useful to have generic, user-defined queries.
I currently store xdId in a property of type String, but that's inefficient.

@lehvolk
Copy link
Contributor

lehvolk commented Apr 26, 2018

There is an extension method XdEntityType.findById. You can wrap result into XdQuery and intersect it with result of query by other properties.

At the moment such NodeBase is not implemented on the database level because there is a direct method to get Entity based on id.

I currently store xdId in a property of type String, but that inefficient.

I don't get your point. Could you please elaborate.

@jansorg
Copy link
Author

jansorg commented Apr 26, 2018

@lehvolk Thanks, I'll have a look at findById.
I meant that I currently have a property called id which stores the value of xdId and which I currently use in NodeBase queries. But I added id before xdId was there and duplicating xdId is inefficient.

@jansorg jansorg closed this as completed Jun 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants