0
在Simple.Data例子集,有「魔法鑄造」的例子:如果有返回多個記錄魔法鑄造結果
// When you assign the dynamic record to a static type, any matching properties are auto-mapped.
var db = Database.Open();
Customer customer = db.Customers.FindByCustomerId(1);
不Simple.Data也神奇地投?事情是這樣的:
var db = Database.Open();
IEnumerable<Customer> customers = db.Customers.FindBySurname("Smith");
很顯然,我已經試過以上,它不工作(「無法隱式轉換類型」從SimpleQuery我的具體類型)。任何的建議都受歡迎。