{"id":6716,"date":"2024-11-14T11:04:20","date_gmt":"2024-11-14T03:04:20","guid":{"rendered":"https:\/\/fwq.ai\/blog\/6716\/"},"modified":"2024-11-14T11:04:20","modified_gmt":"2024-11-14T03:04:20","slug":"%e5%a6%82%e4%bd%95%e5%9c%a8-mysql-%e4%b8%ad%e9%87%8d%e7%bd%ae%e8%87%aa%e5%a2%9e%e5%ad%97%e6%ae%b5%e7%9a%84%e8%b5%b7%e7%82%b9%ef%bc%9f","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/6716\/","title":{"rendered":"\u5982\u4f55\u5728 MySQL \u4e2d\u91cd\u7f6e\u81ea\u589e\u5b57\u6bb5\u7684\u8d77\u70b9\uff1f"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/001\/246\/273\/172981730845283.jpg\" class=\"aligncenter\" title=\"\u5982\u4f55\u5728 MySQL \u4e2d\u91cd\u7f6e\u81ea\u589e\u5b57\u6bb5\u7684\u8d77\u70b9\uff1f\u63d2\u56fe\" alt=\"\u5982\u4f55\u5728 MySQL \u4e2d\u91cd\u7f6e\u81ea\u589e\u5b57\u6bb5\u7684\u8d77\u70b9\uff1f\u63d2\u56fe\" \/><\/p>\n<p><strong>\u5982\u4f55\u5728  \u81ea\u589e\u5b57\u6bb5\u4e2d\u91cd\u7f6e\u81ea\u589e\u8d77\u70b9<\/strong><\/p>\n<p>\u6b63\u5982\u60a8\u5728\u95ee\u9898\u4e2d\u6240\u8ff0\uff0c\u60a8\u624b\u52a8\u66f4\u6539\u4e86\u4e00\u4e2a\u81ea\u589e\u5b57\u6bb5\u7684\u5f53\u524d\u503c\uff0c\u8fd9\u53ef\u80fd\u4f1a\u5bfc\u81f4\u81ea\u589e\u5e8f\u5217\u4e2d\u65ad\u3002\u4ee5\u4e0b\u662f\u5982\u4f55\u5728 mysql \u4e2d\u91cd\u7f6e\u81ea\u589e\u8d77\u70b9\uff1a<\/p>\n<p>\u4f7f\u7528 <strong>alter table<\/strong> \u8bed\u53e5\uff1a<\/p>\n<pre>ALTER TABLE {\u8868\u540d} AUTO_INCREMENT=867;<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p>\u6b64\u8bed\u53e5\u5c06\u4e3a\u6307\u5b9a\u8868\u4e2d\u7684\u81ea\u589e\u5b57\u6bb5\u91cd\u7f6e\u81ea\u589e\u8d77\u70b9\u3002\u8bf7\u6ce8\u610f\uff0cmysql \u4f1a\u68c0\u67e5\u6700\u540e\u4e00\u4e2a\u81ea\u589e id\uff0c\u5e76\u5728\u5176\u57fa\u7840\u4e0a\u52a0 1\u3002\u8fd9\u610f\u5473\u7740\u5982\u679c\u5f53\u524d\u8868\u4e2d\u5b58\u5728\u81ea\u589e id \u4e3a 867 \u7684\u8bb0\u5f55\uff0c\u90a3\u4e48\u91cd\u7f6e\u540e\u7684\u7b2c\u4e00\u4e2a\u63d2\u5165\u8bb0\u5f55\u7684\u81ea\u589e id \u5c06\u4e3a 868\u3002<\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u5728 MySQL \u4e2d\u91cd\u7f6e\u81ea\u589e\u5b57\u6bb5\u7684\u8d77\u70b9\uff1f\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u7f51\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5982\u4f55\u5728 \u81ea\u589e\u5b57\u6bb5\u4e2d\u91cd\u7f6e\u81ea\u589e\u8d77\u70b9 \u6b63\u5982\u60a8\u5728\u95ee\u9898\u4e2d\u6240\u8ff0\uff0c\u60a8\u624b\u52a8\u66f4\u6539\u4e86\u4e00\u4e2a\u81ea\u589e\u5b57\u6bb5\u7684\u5f53\u524d\u503c\uff0c\u8fd9\u53ef\u80fd\u4f1a\u5bfc\u81f4\u81ea\u589e\u5e8f\u5217\u4e2d\u65ad\u3002\u4ee5\u4e0b\u662f\u5982\u4f55\u5728 mysql \u4e2d\u91cd\u7f6e\u81ea\u589e\u8d77\u70b9\uff1a \u4f7f\u7528 alter table \u8bed\u53e5\uff1a ALTER TABLE {\u8868\u540d} AUTO_INCREMENT=867; \u767b\u5f55\u540e\u590d\u5236 \u6b64\u8bed\u53e5\u5c06\u4e3a\u6307\u5b9a\u8868\u4e2d\u7684\u81ea\u589e\u5b57\u6bb5\u91cd\u7f6e\u81ea\u589e\u8d77\u70b9\u3002\u8bf7\u6ce8\u610f\uff0cmysql \u4f1a\u68c0\u67e5\u6700\u540e\u4e00\u4e2a\u81ea\u589e id\uff0c\u5e76\u5728\u5176\u57fa\u7840\u4e0a\u52a0 1\u3002\u8fd9\u610f\u5473\u7740\u5982\u679c\u5f53\u524d\u8868\u4e2d\u5b58\u5728\u81ea\u589e id \u4e3a 867 \u7684\u8bb0\u5f55\uff0c\u90a3\u4e48\u91cd\u7f6e\u540e\u7684\u7b2c\u4e00\u4e2a\u63d2\u5165\u8bb0\u5f55\u7684\u81ea\u589e id \u5c06\u4e3a 868\u3002 \u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u5728 MySQL \u4e2d\u91cd\u7f6e\u81ea\u589e\u5b57\u6bb5\u7684\u8d77\u70b9\uff1f\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u7f51\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-6716","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/6716","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=6716"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/6716\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=6716"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=6716"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=6716"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}