SQL syntax

  • Thread starter Thread starter Christian Dokman
  • Start date Start date
C

Christian Dokman

When I use the LIKE clause in a SQL statement in ASP.NET, it doesn't
seem to work. When I create a query in Microsoft Access and use a Like
clause in the where statement, it works just fine. When I use the same
SQL syntax in ASP.NET, it gives no results. By the way, I use something
like: WHERE (([FieldnameA] = Like ('*Value*')) OR ([FieldnameB] = Like
('*Value*')))
Does anyone know what's the problem here?
 
When using the LIKE keyword, you do not use the = sign. It is just "WHERE
MyField LIKE '%whatever%'"
 
Back
Top