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

Linq queries not working when object name is not match with collection name #373

Open
DilanJayamuni opened this issue May 13, 2024 · 1 comment

Comments

@DilanJayamuni
Copy link

We are facing a problem integrating Linq queries with Couchbase. Basically, "SpinAggregate" in the code is our class name (object name) for the collection and our collection name is "SpinAggregates" in the database (with an "s" added to the end of the class name).

Related to this reason Linq queries are not working correctly on the code. Because our object name and collection name of the DB is different and query is not returning result from DB. Can you tell me how we can solve this problem to use Couchbase Linq queries on code?

I have attached query (code) that how we are quering by using Linq here. That code is correct. But the problem is it not picking data from collection.

I guess _bucketContext dll not picking correct collection from the DB based on object (_bucketContext.Query())

Thank you
Dilan Jayamuni

@brantburnett
Copy link
Collaborator

Dilan,

Try the instructions on using scopes/collections in this document and see if it helps: https://github.com/couchbaselabs/Linq2Couchbase/blob/master/docs/scopes-collections.md

If not, please let me know. Note that your attachments did not come through on the issue in GitHub.

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