Answers
Execute
is the Dapper method that executes a stored procedure, returning no results.QueryFirst
is the Dapper method for reading a single record of data where the record is guaranteed to exist.Query
is the Dapper method for reading a collection of records.- The problem with the query is that it expects a parameter calledÂ
Search
 but we have passed it a parameter calledÂCriteria
. So, Dapper won't be able to map the SQL parameter. - The problem is that the stored procedure returns a field calledÂ
BuildingId
, which won't automatically get mapped to theÂId
 property in the class because the names are different. - Yes!
DbUp
can execute any SQL script, and can also deploy new reference data for a table.