{"id":80,"date":"2018-06-20T14:40:11","date_gmt":"2018-06-20T06:40:11","guid":{"rendered":"http:\/\/www.maoyunwang.top\/?p=80"},"modified":"2018-06-20T14:40:11","modified_gmt":"2018-06-20T06:40:11","slug":"2018%e5%b9%b46%e6%9c%8820%e6%97%a5mybatis%e6%98%a0%e5%b0%84%e6%96%87%e4%bb%b6demo1%e4%b8%80%e7%9b%b4%e5%bf%98%e8%ae%b0%e4%b8%8b%e6%9d%a5","status":"publish","type":"post","link":"https:\/\/blog.tongyunli.top\/?p=80","title":{"rendered":"2018\u5e746\u670820\u65e5MyBatis\u6620\u5c04\u6587\u4ef6demo(1)(\u4e00\u76f4\u5fd8\u8bb0\u4e0b\u6765)"},"content":{"rendered":"<pre class=\"prettyprint\"><span class=\"tag\">&lt;select<\/span> <span class=\"atn\">id<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"selectPerson\"<\/span> <span class=\"atn\">parameterType<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"int\"<\/span> <span class=\"atn\">resultType<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"hashmap\"<\/span><span class=\"tag\">&gt;<\/span><span class=\"pln\">\n  SELECT * FROM PERSON WHERE ID = #{id}\n<\/span><span class=\"tag\">&lt;\/select&gt;\n\n<\/span><\/pre>\n<pre class=\"prettyprint\"><span class=\"tag\">&lt;select<\/span>\n  <span class=\"atn\">id<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"selectPerson\"             \/\/\u547d\u540d\u7a7a\u95f4\u552f\u4e00\u6807\u8bc6 \u88ab\u5f15\u7528<\/span>\n  <span class=\"atn\">parameterType<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"int\"           \/\/\u4f20\u5165\u8fd9\u6761\u8bed\u53e5\u7684\u5b8c\u5168\u9650\u5b9a\u6216\u8005\u522b\u540d,\u53ef\u9009<\/span>\n  <span class=\"atn\">parameterMap<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"deprecated\"     \/\/\u5df2\u5e9f\u5f03,<\/span>\n  <span class=\"atn\">resultType<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"hashmap\"          \/\/\u8fd4\u56de\u671f\u5f85\u7c7b\u578b\u7684\u7c7b\u6216\u8005\u9650\u5b9a\u540d<\/span>\n  <span class=\"atn\">resultMap<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"personResultMap\"   \/\/\u5916\u90e8requestMap \u7684\u547d\u540d\u5f15\u7528,\u7ed3\u679c\u96c6\u6620\u5c04 \u4e0d\u80fd\u4e0erequestType\u540c\u65f6\u4f7f\u7528<\/span>\n  <span class=\"atn\">flushCache<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"false\"            \/\/\u4e3aTrue\u65f6\u53ea\u8981\u8bed\u53e5\u88ab\u8c03\u7528\u90fd\u4f1a\u6e05\u7a7a\u672c\u5730\u7f13\u5b58\u548c\u4e8c\u7ea7\u7f13\u5b58 \u9ed8\u8ba4 \u4e3a False<\/span>\n  <span class=\"atn\">useCache<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"true\"               \/\/\u4e3aTrue\u65f6\u4f1a\u4f7f\u672c\u6761\u8bed\u53e5\u7684\u7ed3\u679c\u88ab\u4e8c\u7ea7\u7f13\u5b58 \u9ed8\u8ba4\u503c \u5bf9select\u4e3aTrue<\/span>\n  <span class=\"atn\">timeout<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"10000\"               \/\/\u8bbe\u7f6e\u629b\u51fa\u5f02\u5e38\u4e4b\u524d\u9a71\u52a8\u7a0b\u5e8f\u7b49\u5f85\u7684\u65f6\u95f4 \u5355\u4f4d : \u79d2  \u9ed8\u8ba4 unset<\/span>\n  <span class=\"atn\">fetchSize<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"256\"               \/\/\u5c1d\u8bd5\u5f71\u54cd\u9a71\u52a8\u6bcf\u6b21\u6279\u91cf\u8fd4\u56de\u7684\u7ed3\u679c\u884c\u6570\u4e3a\u8bbe\u7f6e\u503c \u9ed8\u8ba4 unset<\/span>\n  <span class=\"atn\">statementType<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"PREPARED\"      \/\/STATEMENT\uff0cPREPARED \u6216 CALLABLE \u7684\u4e00\u4e2a\u3002\u8fd9\u4f1a\u8ba9 MyBatis \u5206\u522b\u4f7f\u7528 Statement\uff0cPreparedStatement \u6216 CallableStatement\uff0c\u9ed8\u8ba4\u503c\uff1aPREPARED\u3002<\/span>\n  <span class=\"atn\">resultSetType<\/span><span class=\"pun\">=<\/span><span class=\"atv\">\"FORWARD_ONLY\"<\/span><span class=\"tag\">&gt; \/\/FORWARD_ONLY\uff0cSCROLL_SENSITIVE \u6216 SCROLL_INSENSITIVE \u4e2d\u7684\u4e00\u4e2a\uff0c\u9ed8\u8ba4\u503c\u4e3a unset \uff08\u4f9d\u8d56\u9a71\u52a8\uff09<\/span><\/pre>\n<pre class=\"prettyprint\"><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>&lt;select id=&#8221;selectPerson&#8221; parameterType=&#8221;int&#8221; result [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[62],"class_list":["post-80","post","type-post","status-publish","format-standard","hentry","category-jishu","tag-zongjie"],"_links":{"self":[{"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=\/wp\/v2\/posts\/80","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=80"}],"version-history":[{"count":0,"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=\/wp\/v2\/posts\/80\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=80"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=80"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.tongyunli.top\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=80"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}