lundi 29 juin 2015

Error when using LIKE in report builder

I'm trying to use LIKE in report builder and I got this error:

An error occurred while reading data from the query result set.
Conversion failed when converting the varchar value '%' to data type int.
(Microsoft SQL Server, Error: 245)

this is my code:

select count(*) from projects where received LIKE '%'+@received+'%'
and institution# = @institution and program# = @program

how could i solve it?

Aucun commentaire:

Enregistrer un commentaire