Following section demonstrates how to execute the DbCommand.
// DbCommand is being prepared
var cmd = cn.CreateCommand(
"DELETE FROM table WHERE field1<>@p1 AND field2=@p2",
new { p1 = 0, p2 = "X"});
var affectedRows = connection.ExecuteNonQuery(cmd);