Click here to Skip to main content
15,892,005 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
C#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace LINQ
{
    class Program
    {
        static void Main(string[] args)
        {
            NorthwindEntities linq = new NorthwindEntities();
            IEnumerable<employee> emps=    linq.Employees.Where(x => x.TitleOfCourtesy == "Ms." || x.Title == "Sales Representative");

            IEnumerable<customer> csts = linq.Customers.Where(x => x.Country == "Mexico");
            var v = from l1 in emps
                    join l2 in csts
                        on l1.EmployeeID equals l2.CustomerID
                    select l1.Title;           
        
        }
    }
}
Posted
Updated 20-Sep-14 5:04am
v2

1 solution

Either your employeeid and customerid are not same else there is problem in datatypes of both the ids
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900