{"action":"created","issue":{"url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/issues/308","repository_url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc","labels_url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/issues/308/labels{/name}","comments_url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/issues/308/comments","events_url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/issues/308/events","html_url":"https://github.com/dangdangdotcom/sharding-jdbc/issues/308","id":247359562,"number":308,"title":"数据库自增GeneratedKey的返回无效，已经确认不支持。","user":{"login":"xuminwlt","id":5835937,"avatar_url":"https://avatars1.githubusercontent.com/u/5835937?v=4","gravatar_id":"","url":"https://api.github.com/users/xuminwlt","html_url":"https://github.com/xuminwlt","followers_url":"https://api.github.com/users/xuminwlt/followers","following_url":"https://api.github.com/users/xuminwlt/following{/other_user}","gists_url":"https://api.github.com/users/xuminwlt/gists{/gist_id}","starred_url":"https://api.github.com/users/xuminwlt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xuminwlt/subscriptions","organizations_url":"https://api.github.com/users/xuminwlt/orgs","repos_url":"https://api.github.com/users/xuminwlt/repos","events_url":"https://api.github.com/users/xuminwlt/events{/privacy}","received_events_url":"https://api.github.com/users/xuminwlt/received_events","type":"User","site_admin":false},"labels":[{"id":312935313,"url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-08-02T11:36:58Z","updated_at":"2017-08-02T15:28:54Z","closed_at":"2017-08-02T15:28:54Z","body":"Please answer these questions before submitting your issue. Thanks!\r\n\r\n### Which version of Sharding-Jdbc do you using?\r\n1.5.0\r\n### Expected behavior\r\nmysql自增id在Mybatis中能拿到\r\n\r\n@Options(useGeneratedKeys = true, keyProperty = \"id\" )\r\n    boolean add(User user);\r\n\r\n### Actual behavior\r\n\r\n配置sjdbc的<rdb:generate-key-column column-name=\"id\"/>意味着只能使用分布式id策略，无法满足现有需求，1.4.2一直可以的。\r\n\r\n### Steps to reproduce the behavior\r\n\r\n <insert id=\"insert\" useGeneratedKeys=\"true\" keyProperty=\"orderId\">\r\n        INSERT INTO t_order (\r\n          user_id, status\r\n        )\r\n        VALUES (\r\n        #{userId,jdbcType=INTEGER},\r\n        #{status,jdbcType=VARCHAR}\r\n        )\r\n    </insert>\r\n\r\n### Please provide the reproduce example codes (such as github link) if possible.\r\n\r\n能够像1.4.2一样支持数据库自增id返回GeneratedKey策略，经过调试发现，GeneratedKey仅在配置分布式自增id才会生效。"},"comment":{"url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/issues/comments/319707847","html_url":"https://github.com/dangdangdotcom/sharding-jdbc/issues/308#issuecomment-319707847","issue_url":"https://api.github.com/repos/dangdangdotcom/sharding-jdbc/issues/308","id":319707847,"user":{"login":"terrymanu","id":5516298,"avatar_url":"https://avatars1.githubusercontent.com/u/5516298?v=4","gravatar_id":"","url":"https://api.github.com/users/terrymanu","html_url":"https://github.com/terrymanu","followers_url":"https://api.github.com/users/terrymanu/followers","following_url":"https://api.github.com/users/terrymanu/following{/other_user}","gists_url":"https://api.github.com/users/terrymanu/gists{/gist_id}","starred_url":"https://api.github.com/users/terrymanu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/terrymanu/subscriptions","organizations_url":"https://api.github.com/users/terrymanu/orgs","repos_url":"https://api.github.com/users/terrymanu/repos","events_url":"https://api.github.com/users/terrymanu/events{/privacy}","received_events_url":"https://api.github.com/users/terrymanu/received_events","type":"User","site_admin":false},"created_at":"2017-08-02T15:28:54Z","updated_at":"2017-08-02T15:28:54Z","body":"fixed at 1.5.1"}}
{"actor":{"display_login":"terrymanu"}}