{"action":"opened","issue":{"url":"https://api.github.com/repos/StackExchange/Dapper/issues/877","repository_url":"https://api.github.com/repos/StackExchange/Dapper","labels_url":"https://api.github.com/repos/StackExchange/Dapper/issues/877/labels{/name}","comments_url":"https://api.github.com/repos/StackExchange/Dapper/issues/877/comments","events_url":"https://api.github.com/repos/StackExchange/Dapper/issues/877/events","html_url":"https://github.com/StackExchange/Dapper/issues/877","id":272995921,"number":877,"title":"Cannot insert boolean using oracle","user":{"login":"dvoaviarisonld","id":29382401,"avatar_url":"https://avatars3.githubusercontent.com/u/29382401?v=4","gravatar_id":"","url":"https://api.github.com/users/dvoaviarisonld","html_url":"https://github.com/dvoaviarisonld","followers_url":"https://api.github.com/users/dvoaviarisonld/followers","following_url":"https://api.github.com/users/dvoaviarisonld/following{/other_user}","gists_url":"https://api.github.com/users/dvoaviarisonld/gists{/gist_id}","starred_url":"https://api.github.com/users/dvoaviarisonld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dvoaviarisonld/subscriptions","organizations_url":"https://api.github.com/users/dvoaviarisonld/orgs","repos_url":"https://api.github.com/users/dvoaviarisonld/repos","events_url":"https://api.github.com/users/dvoaviarisonld/events{/privacy}","received_events_url":"https://api.github.com/users/dvoaviarisonld/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-11-10T16:55:19Z","updated_at":"2017-11-10T16:55:19Z","closed_at":null,"author_association":"NONE","body":"sqlQuery variable\r\n```sql\r\ninsert into SomeTable (\r\n  SomeBoolValue // number(1, 0)\r\n) values (\r\n  :SomeBoolValue\r\n);\r\n```\r\nDapper call\r\n``` csharp\r\nClass SomeTable {\r\n  bool SomeBoolValue\r\n}\r\n...\r\nvar values = new SomeTable{SomeBoolValue = false};\r\nthis.conn.ExecuteAsync(sqlQuery, values );\r\n```\r\nThat is causing an exception.\r\n\r\nI tried to create a BoolTypeHandler but was not even called\r\n```csharp\r\n         {\r\n               ...\r\n               SqlMapper.AddTypeHandlerImpl(typeof(bool), new BoolTypeHandler(), true);\r\n              ...\r\n         }\r\n\r\n        public class BoolTypeHandler : SqlMapper.TypeHandler<bool>\r\n        {\r\n            public override void SetValue(IDbDataParameter parameter, bool value)\r\n            {\r\n                parameter.Value = value ? (byte)1 : (byte)0;\r\n            }\r\n\r\n            public override bool Parse(object value)\r\n            {\r\n                return bool.Parse((string)value);\r\n            }\r\n        }\r\n```"}}
{"actor":{"display_login":"dvoaviarisonld"}}