LINQ string.contains problem

Oct 27, 2010 at 8:37 AM

Hi,

 

I have a very annoying problem with linq. I have the following query:

 

  Dim records = (From icscodes In context.ICS_CODES_SOFTW_ALARM _
Where icscodes.ICS_CODE.Contains(e.Text) _
Select icscodes.ICS_CODE, icscodes.ICS_OMSCHRIJVING).ToList()

 

the recordset of ICS codes are:

"00"

"00B"

"00B1"

"00B10"

 

when i search for the string "00B" in the contains clause, i get a result of:

"00" and "00B"

what i would expect is:

"00B" , "00B1"  and "00B10"

 

 

if i query a regular list, the results are okay. But when i use the database, things get weird.

Could this be an issue of the provider?