c# - Does Dapper support Enums? -


i have class user role enum values: employee, admin etc... dapper throws exception: "the member role of type system.enum cannot used parameter value"

does dapper support enums?

    idbconnection connection connection.execute(sb.tostring(), entitytoinsert, /*transaction: transaction*/tx, commandtimeout: commandtimeout); 

enums supported, enum isn't :p

so if have:

class user {     public memberrole role {get;set;} } 

then should work fine; however

class user {     public enum role {get;set;} } 

will not. perhaps using latter?


Comments

Popular posts from this blog

c# - Operator '==' incompatible with operand types 'Guid' and 'Guid' using DynamicExpression.ParseLambda<T, bool> -