[CSHARP-3197] Make applying SelectSelectCombiningTransformer on expressions optional Created: 24/Aug/20 Updated: 27/Oct/23 Resolved: 01/Nov/22 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | Linq |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Hesam Faridmehr | Assignee: | Robert Stam |
| Resolution: | Works as Designed | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
In some cases when we are building dynamic expressions, it is possible to end up using multiple projections, for example:
Applying SelectSelectCombiningTransformer make this LINQ to be combined and end up in NotSupportedException. I removed the transformer and there was no side effects, just two of tests were failed which excepted the exact query. Here are name of the tests:
If we could make usage of this transformer optional, it will cover more situations.
|
| Comments |
| Comment by Hesam Faridmehr [ 01/Nov/22 ] | ||||
|
Great, thanks | ||||
| Comment by Robert Stam [ 01/Nov/22 ] | ||||
|
This issue has been fixed in the new LINQ provider (known as LINQ3), which was introduced in the 2.14 release. Configure your MongoClientSettings to use LinqProvider.V3 if you want to use this functionality. To configure a client to use the LINQ3 provider use code like the following
| ||||
| Comment by Githook User [ 01/Nov/22 ] | ||||
|
Author: {'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}Message: | ||||
| Comment by Esha Bhargava [ 14/Sep/20 ] | ||||
|
faridmehr.hesam@gmail.com Thanks for reporting this issue. We are in the process of a major redesign of our LINQ provider and will consider this as a part of that effort. |