I have a problem with my query using dapper, whether someone imagine to help me and say where I'm doing the wrong, is currently showing me an error at the date when I put a breik point, how to correct it properly? thank you all for help
this is my current code
public string GetBezeichnung(int LP, DateTime date)
{
using (IDbConnection connection = new System.Data.SqlClient.SqlConnection())
{
connection.ConnectionString = _ConnectionString;
var output = connection.Query<string>("SELECT ZER_Bezeichnung FROM Z_ERFASSUNG WHERE ZER_LPE = " + LP + " AND ZER_Datum = " + date).FirstOrDefault();
return output;
}
}
and this is the result with which I get an error
