This documentation is archived and is not being maintained.

'And' expected

Visual Studio 2008

A comparison operator other than And has been used to combine two or more Equals operators in a Join or Group Join clause. Only the And operator is allowed to combine multiple Equals operators in a Join or Group Join clause.

Error ID: BC36620

To correct this error

  • Restructure the Equals clauses to make comparisons by using only the And operator. The following is an example:

    Dim petOwnersJoin = From pers In people _
                        Join pet In pets _
                        On pet.Owner Equals pers And _
                           pet.Name = pers.PetName_
                        Select pers, pet
    
Show: