Im getting table tags from db.
table has column identifiers and tag
I am doing something like this to get a list of strings:
var taglist = Model.Tags.Select(x => x.TagName.ToLower()).ToArray();
then I compare with another string array to get the strings that are found in both:
var intersectList = tagList.Intersect(anotherList);
I have a list, but now I also want the identifier of each element to remain in the intersection list that matches the tagList. (maybe just an int array)
Can someone help with a good way to do this?
source share