{"id":7450,"date":"2024-11-14T08:43:04","date_gmt":"2024-11-14T00:43:04","guid":{"rendered":"https:\/\/fwq.ai\/blog\/7450\/"},"modified":"2024-11-14T08:43:04","modified_gmt":"2024-11-14T00:43:04","slug":"%e7%99%be%e4%b8%87%e6%95%b0%e6%8d%ae%e9%87%8f-mysql-%e6%a8%a1%e7%b3%8a%e6%90%9c%e7%b4%a2%e6%8f%90%e9%80%9f%ef%bc%9a%e5%a6%82%e4%bd%95%e5%9c%a8-512m-%e5%86%85%e5%ad%98%e9%99%90%e5%88%b6%e4%b8%8b","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/7450\/","title":{"rendered":"\u767e\u4e07\u6570\u636e\u91cf MySQL \u6a21\u7cca\u641c\u7d22\u63d0\u901f\uff1a\u5982\u4f55\u5728 512M \u5185\u5b58\u9650\u5236\u4e0b\u4f18\u5316\u67e5\u8be2\u901f\u5ea6\uff1f"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/001\/246\/273\/173086758441268.jpg\" class=\"aligncenter\" title=\"\u767e\u4e07\u6570\u636e\u91cf MySQL \u6a21\u7cca\u641c\u7d22\u63d0\u901f\uff1a\u5982\u4f55\u5728 512M \u5185\u5b58\u9650\u5236\u4e0b\u4f18\u5316\u67e5\u8be2\u901f\u5ea6\uff1f\u63d2\u56fe\" alt=\"\u767e\u4e07\u6570\u636e\u91cf MySQL \u6a21\u7cca\u641c\u7d22\u63d0\u901f\uff1a\u5982\u4f55\u5728 512M \u5185\u5b58\u9650\u5236\u4e0b\u4f18\u5316\u67e5\u8be2\u901f\u5ea6\uff1f\u63d2\u56fe\" \/><\/p>\n<p><strong>\u767e\u4e07\u6570\u636e\u91cf  \u6a21\u7cca\u641c\u7d22\u63d0\u901f<\/strong><\/p>\n<p>\u5728 mysql \u4e2d\uff0c\u5f53\u6570\u636e\u91cf\u8fbe\u5230\u767e\u4e07\u7ea7\u65f6\uff0c\u6267\u884c\u6a21\u7cca\u67e5\u8be2\u53ef\u80fd\u4f1a\u53d8\u5f97\u975e\u5e38\u7f13\u6162\u3002\u672c\u6587\u63d0\u4f9b\u7684\u89e3\u51b3\u65b9\u6848\u65e0\u9700\u501f\u52a9\u7b2c\u4e09\u65b9\u4e2d\u95f4\u4ef6\uff0c\u5373\u53ef\u5728 512m \u7684 java \u5806\u5185\u5b58\u9650\u5236\u4e0b\u663e\u7740\u63d0\u5347\u6a21\u7cca\u641c\u7d22\u7684\u901f\u5ea6\u3002 <\/p>\n<p><strong>\u57fa\u4e8e\u7d22\u5f15\u8868\u7684\u65b9\u6848<\/strong><\/p>\n<p>\u521b\u5efa\u4e00\u4e2a\u7d22\u5f15\u8868\uff0c\u5305\u542b\u4e09\u5217\uff1a&#8221;\u5f53\u524d\u8bcd&#8221;\u3001&#8221;\u4e0b\u4e00\u8bcd&#8221;\u548c&#8221;\u539f\u8bb0\u5f55\u4e3b\u952e id&#8221;\u3002\u5176\u4e2d\uff0c&#8221;\u5f53\u524d\u8bcd&#8221;\u548c&#8221;\u4e0b\u4e00\u8bcd&#8221;\u8868\u793a\u641c\u7d22\u5173\u952e\u8bcd\u4e2d\u7684\u8fde\u7eed\u5355\u8bcd\uff0c&#8221;\u539f\u8bb0\u5f55\u4e3b\u952e id&#8221;\u6307\u5411\u6ee1\u8db3\u6761\u4ef6\u7684\u539f\u59cb\u8bb0\u5f55\u3002 <\/p>\n<p><strong>\u7d22\u5f15\u8868\u7ed3\u6784<\/strong><\/p>\n<table>\n<thead>\n<tr>\n<th>\u5f53\u524d\u8bcd<\/th>\n<th>\u4e0b\u4e00\u8bcd<\/th>\n<th>\u539f\u8bb0\u5f55\u4e3b\u952e id<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>mysql<\/td>\n<td>\u4e00<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>\u4e00<\/td>\n<td>\u5343<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>\u5343<\/td>\n<td>\u4e07<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>\u4e07<\/td>\n<td>\u7684<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>&#8230;<\/td>\n<td>&#8230;<\/td>\n<td>&#8230;<\/td>\n<\/tr>\n<tr>\n<td>\u6a21<\/td>\n<td>\u7cca<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>\u7cca<\/td>\n<td>\u641c<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>\u641c<\/td>\n<td>\u7d22<\/td>\n<td>1<\/td>\n<\/tr>\n<tr>\n<td>\u7d22<\/td>\n<td>null<\/td>\n<td>1<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>\u641c\u7d22\u7b97\u6cd5<\/strong><\/p>\n<p>\u641c\u7d22\u5173\u952e\u8bcd\u65f6\uff0c\u6309\u987a\u5e8f\u67e5\u8be2\u7d22\u5f15\u8868\uff0c\u83b7\u5f97\u6ee1\u8db3\u6bcf\u4e2a\u5355\u8bcd\u6761\u4ef6\u7684\u539f\u8bb0\u5f55id\u3002\u7136\u540e\u4f7f\u7528\u8fd9\u4e9b id \u5728\u539f\u59cb\u8868\u4e2d\u67e5\u627e\u5339\u914d\u8bb0\u5f55\u3002 <\/p>\n<p><strong>\u4f8b\uff1a\u641c\u7d22\u201c\u6a21\u7cca\u641c\u7d22\u201d<\/strong><\/p>\n<pre>SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID\n  FROM (SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID FROM \u7d22\u5f15\u8868 WHERE \u5f53\u524d\u8bcd = '\u6a21' AND \u4e0b\u4e00\u8bcd = '\u7cca')\n  JOIN (SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID FROM \u7d22\u5f15\u8868 WHERE \u5f53\u524d\u8bcd = '\u7cca' AND \u4e0b\u4e00\u8bcd = '\u641c') USING(\u539f\u8bb0\u5f55\u4e3b\u952eID)\n  JOIN (SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID FROM \u7d22\u5f15\u8868 WHERE \u5f53\u524d\u8bcd = '\u641c' AND \u4e0b\u4e00\u8bcd = '\u7d22') USING(\u539f\u8bb0\u5f55\u4e3b\u952eID)\n  JOIN (SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID FROM \u7d22\u5f15\u8868 WHERE \u5f53\u524d\u8bcd = '\u7d22' AND \u4e0b\u4e00\u8bcd IS NULL) USING(\u539f\u8bb0\u5f55\u4e3b\u952eID)<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p><strong>jvm \u4f18\u5316<\/strong><\/p>\n<p>\u4e3a\u4e86\u5145\u5206\u5229\u7528\u6709\u9650\u7684\u5185\u5b58\uff0c\u5efa\u8bae\u4f7f\u7528\u5982\u4e0b\u7684jvm \u4f18\u5316\u6280\u672f\uff1a<\/p>\n<ul>\n<li>\u7f29\u5c0f\u6c38\u4e45\u4ee3\u5c3a\u5bf8<\/li>\n<li>\u8bbe\u7f6emetaspace \u5783\u573e\u56de\u6536\u53c2\u6570\uff08-xx:metaspacesize\u3001-xx:maxmetaspacesize\uff09<\/li>\n<li>\u4f7f\u7528\u538b\u7f29\u5f15\u7528\u548c\u6307\u9488<\/li>\n<li>\u542f\u7528\u5206\u4ee3\u5783\u573e\u56de\u6536<\/li>\n<\/ul>\n<p>\u4ee5\u4e0a\u5c31\u662f\u767e\u4e07\u6570\u636e\u91cf MySQL \u6a21\u7cca\u641c\u7d22\u63d0\u901f\uff1a\u5982\u4f55\u5728 512M \u5185\u5b58\u9650\u5236\u4e0b\u4f18\u5316\u67e5\u8be2\u901f\u5ea6\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>\u767e\u4e07\u6570\u636e\u91cf \u6a21\u7cca\u641c\u7d22\u63d0\u901f \u5728 mysql \u4e2d\uff0c\u5f53\u6570\u636e\u91cf\u8fbe\u5230\u767e\u4e07\u7ea7\u65f6\uff0c\u6267\u884c\u6a21\u7cca\u67e5\u8be2\u53ef\u80fd\u4f1a\u53d8\u5f97\u975e\u5e38\u7f13\u6162\u3002\u672c\u6587\u63d0\u4f9b\u7684\u89e3\u51b3\u65b9\u6848\u65e0\u9700\u501f\u52a9\u7b2c\u4e09\u65b9\u4e2d\u95f4\u4ef6\uff0c\u5373\u53ef\u5728 512m \u7684 java \u5806\u5185\u5b58\u9650\u5236\u4e0b\u663e\u7740\u63d0\u5347\u6a21\u7cca\u641c\u7d22\u7684\u901f\u5ea6\u3002 \u57fa\u4e8e\u7d22\u5f15\u8868\u7684\u65b9\u6848 \u521b\u5efa\u4e00\u4e2a\u7d22\u5f15\u8868\uff0c\u5305\u542b\u4e09\u5217\uff1a&#8221;\u5f53\u524d\u8bcd&#8221;\u3001&#8221;\u4e0b\u4e00\u8bcd&#8221;\u548c&#8221;\u539f\u8bb0\u5f55\u4e3b\u952e id&#8221;\u3002\u5176\u4e2d\uff0c&#8221;\u5f53\u524d\u8bcd&#8221;\u548c&#8221;\u4e0b\u4e00\u8bcd&#8221;\u8868\u793a\u641c\u7d22\u5173\u952e\u8bcd\u4e2d\u7684\u8fde\u7eed\u5355\u8bcd\uff0c&#8221;\u539f\u8bb0\u5f55\u4e3b\u952e id&#8221;\u6307\u5411\u6ee1\u8db3\u6761\u4ef6\u7684\u539f\u59cb\u8bb0\u5f55\u3002 \u7d22\u5f15\u8868\u7ed3\u6784 \u5f53\u524d\u8bcd \u4e0b\u4e00\u8bcd \u539f\u8bb0\u5f55\u4e3b\u952e id mysql \u4e00 1 \u4e00 \u5343 1 \u5343 \u4e07 1 \u4e07 \u7684 1 &#8230; &#8230; &#8230; \u6a21 \u7cca 1 \u7cca \u641c 1 \u641c \u7d22 1 \u7d22 null 1 \u641c\u7d22\u7b97\u6cd5 \u641c\u7d22\u5173\u952e\u8bcd\u65f6\uff0c\u6309\u987a\u5e8f\u67e5\u8be2\u7d22\u5f15\u8868\uff0c\u83b7\u5f97\u6ee1\u8db3\u6bcf\u4e2a\u5355\u8bcd\u6761\u4ef6\u7684\u539f\u8bb0\u5f55id\u3002\u7136\u540e\u4f7f\u7528\u8fd9\u4e9b id \u5728\u539f\u59cb\u8868\u4e2d\u67e5\u627e\u5339\u914d\u8bb0\u5f55\u3002 \u4f8b\uff1a\u641c\u7d22\u201c\u6a21\u7cca\u641c\u7d22\u201d SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID FROM (SELECT \u539f\u8bb0\u5f55\u4e3b\u952eID [&hellip;]<\/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-7450","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/7450","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=7450"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/7450\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=7450"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=7450"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=7450"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}