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

[API Proposal]: Add left join #97492

Closed
Mr0N opened this issue Jan 25, 2024 · 4 comments
Closed

[API Proposal]: Add left join #97492

Mr0N opened this issue Jan 25, 2024 · 4 comments
Labels
api-suggestion Early API idea and discussion, it is NOT ready for implementation area-System.Linq wishlist Issue we would like to prioritize, but we can't commit we will get to it yet
Milestone

Comments

@Mr0N
Copy link

Mr0N commented Jan 25, 2024

Background and motivation

I suggest adding the LeftJoin method to Linq JObject, it is useful if you need to find elements that were not joined

API Proposal

API Usage

var en = Enumerable.Range(1, 10).Select(a=>a.ToString());
var en2 = Enumerable.Range(1, 5).Select(a => a.ToString());



var result = en2.LeftJoin(en, a => a, x => x, (en2, en) =>
{
    return new { joinResultEn = en,joinResultEn2=en2};
})
    .Where(a=>a.joinResultEn is null)
    .ToList();//

Alternative Designs

No response

Risks

No response

@Mr0N Mr0N added the api-suggestion Early API idea and discussion, it is NOT ready for implementation label Jan 25, 2024
@ghost ghost added the untriaged New issue has not been triaged by the area owner label Jan 25, 2024
@ghost
Copy link

ghost commented Jan 25, 2024

Tagging subscribers to this area: @dotnet/area-system-linq
See info in area-owners.md if you want to be subscribed.

Issue Details

Background and motivation

I suggest adding the LeftJoin method to Linq JObject, it is useful if you need to find elements that were not joined

API Proposal

API Usage

var en = Enumerable.Range(1, 10).Select(a=>a.ToString());
var en2 = Enumerable.Range(1, 5).Select(a => a.ToString());



var result = en2.LeftJoin(en, a => a, x => x, (en2, en) =>
{
    return new { joinResultEn = en,joinResultEn2=en2};
})
    .Where(a=>a.joinResultEn is null)
    .ToList();//select element is not find left join

Alternative Designs

No response

Risks

No response

Author: Mr0N
Assignees: -
Labels:

api-suggestion, area-System.Linq

Milestone: -

@Abdragiz
Copy link

https://learn.microsoft.com/en-us/dotnet/csharp/linq/perform-left-outer-joins

As far as I understand, it's possible to perform a left join with the existing API.

@eiriktsarpalis eiriktsarpalis added this to the Future milestone Jan 25, 2024
@ghost ghost removed the untriaged New issue has not been triaged by the area owner label Jan 25, 2024
@eiriktsarpalis eiriktsarpalis added wishlist Issue we would like to prioritize, but we can't commit we will get to it yet untriaged New issue has not been triaged by the area owner labels Jan 25, 2024
@teo-tsirpanis teo-tsirpanis removed the untriaged New issue has not been triaged by the area owner label Jan 25, 2024
@roji
Copy link
Member

roji commented Dec 1, 2024

Closing in favor of #110292, which is a full API proposal.

@roji roji closed this as not planned Won't fix, can't repro, duplicate, stale Dec 1, 2024
@roji
Copy link
Member

roji commented Dec 1, 2024

Duplicate of #110292

@roji roji marked this as a duplicate of #110292 Dec 1, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Jan 1, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
api-suggestion Early API idea and discussion, it is NOT ready for implementation area-System.Linq wishlist Issue we would like to prioritize, but we can't commit we will get to it yet
Projects
None yet
Development

No branches or pull requests

5 participants