I'm trying to use Massive "dynamic ORM" by Rob Conery to query my DB (working GREAT so far). Ran into a problem when I added a Geography field to my tables.
Here's the error:
UdtTypeName property must be set for UDT parameters
Update (14Apr2011): The ADO method that is throwing the exception is .ExecuteNonQuery();
Here's the method from Massive.cs that throws the exception:
public virtual int Execute(IEnumerable<DbCommand> commands) {
var result = 0;
using (var conn = OpenConnection()) {
using (var tx = conn.BeginTransaction()) {
foreach (var cmd in commands) {
cmd.Connection = conn;
cmd.Transaction = tx;
result += cmd.ExecuteNonQuery();
}
tx.Commit();
}
}
return result;
}
The specific line that throws it is: result += cmd.ExecuteNonQuery();
Here's the important bits of the table:
- PlaceId - bigint PK
- Name - nvarchar
- GeoLocation (Geography type - as a Point)
- ...
It's hard to find any others out there using Massive, but I did report the error on Massive's GitHub Issues tab. You can view the source code for Massive here.