{"id":26903,"date":"2024-11-24T17:55:38","date_gmt":"2024-11-24T09:55:38","guid":{"rendered":"https:\/\/fwq.ai\/blog\/26903\/"},"modified":"2024-11-24T17:55:38","modified_gmt":"2024-11-24T09:55:38","slug":"%e5%a6%82%e4%bd%95%e5%88%a0%e9%99%a4%e6%95%b0%e6%8d%ae%e5%ba%93%e4%b8%ad%e7%89%b9%e5%ae%9a%e5%ad%97%e6%ae%b5%e7%9b%b8%e5%90%8c%e4%bd%86%e7%89%b9%e5%ae%9a%e5%88%97%e5%80%bc%e4%b8%ba%e7%a9%ba%e7%9a%84-2","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/26903\/","title":{"rendered":"\u5982\u4f55\u5220\u9664\u6570\u636e\u5e93\u4e2d\u7279\u5b9a\u5b57\u6bb5\u76f8\u540c\u4f46\u7279\u5b9a\u5217\u503c\u4e3a\u7a7a\u7684\u884c\uff1f"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/001\/246\/273\/173112444376839.jpg\" class=\"aligncenter\" title=\"\u5982\u4f55\u5220\u9664\u6570\u636e\u5e93\u4e2d\u7279\u5b9a\u5b57\u6bb5\u76f8\u540c\u4f46\u7279\u5b9a\u5217\u503c\u4e3a\u7a7a\u7684\u884c\uff1f\u63d2\u56fe\" alt=\"\u5982\u4f55\u5220\u9664\u6570\u636e\u5e93\u4e2d\u7279\u5b9a\u5b57\u6bb5\u76f8\u540c\u4f46\u7279\u5b9a\u5217\u503c\u4e3a\u7a7a\u7684\u884c\uff1f\u63d2\u56fe\" \/><\/p>\n<p><strong>\u5982\u4f55\u5220\u9664\u6570\u636e\u5e93\u4e2d\u7279\u5b9a\u5b57\u6bb5\u76f8\u540c\u4f46\u7279\u5b9a\u5217\u503c\u4e3a\u7a7a\u7684\u884c<\/strong><\/p>\n<p>\u6570\u636e\u5e93\u4e2d\u7684\u8868\u901a\u5e38\u5305\u542b\u591a\u4e2a\u5b57\u6bb5\u3002\u5982\u679c\u67d0\u4e2a\u5b57\u6bb5\u503c\u4e3a\u7a7a\uff0c\u800c\u5176\u4ed6\u5b57\u6bb5\u503c\u76f8\u540c\uff0c\u5219\u53ef\u80fd\u9700\u8981\u5220\u9664\u8fd9\u4e9b\u7a7a\u503c\u884c\uff0c\u4ee5\u4fdd\u6301\u6570\u636e\u7684\u5b8c\u6574\u6027\u3002<\/p>\n<p>\u5728\u63d0\u4f9b\u7684\u793a\u4f8b\u4e2d\uff0cdatas\u8868\u4e2d\u6709\u4ee5\u4e0b\u6570\u636e\uff1a<\/p>\n<table>\n<thead>\n<tr>\n<th>credit<\/th>\n<th>company<\/th>\n<th>name<\/th>\n<th>phone<\/th>\n<th>id<\/th>\n<th>pid<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u5f20\u4e09<\/td>\n<td>3930<\/td>\n<td>21d4f7<\/td>\n<td>null<\/td>\n<\/tr>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u5f20\u4e09<\/td>\n<td>3930<\/td>\n<td>21d4f7<\/td>\n<td>6ec897<\/td>\n<\/tr>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u738b\u4e94<\/td>\n<td>1895<\/td>\n<td>2c6dcd<\/td>\n<td>21d4f7<\/td>\n<\/tr>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u738b\u4e94<\/td>\n<td>1895<\/td>\n<td>a8c70b<\/td>\n<td>21d4f7<\/td>\n<\/tr>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u674e\u56db<\/td>\n<td>9894<\/td>\n<td>33db09<\/td>\n<td>21d4f7<\/td>\n<\/tr>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u674e\u56db<\/td>\n<td>9894<\/td>\n<td>703e16<\/td>\n<td>null<\/td>\n<\/tr>\n<tr>\n<td>99284<\/td>\n<td>\u4f20\u5a92\u6709\u9650\u516c\u53f8<\/td>\n<td>\u674e\u56db<\/td>\n<td>9894<\/td>\n<td>0faa54<\/td>\n<td>21d4f7<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u76ee\u6807\u662f\u5220\u9664pid\u4e3a\u7a7a\u7684name\u4e3a\u5f20\u4e09\u7684\u884c\uff0c\u540c\u65f6\u4fdd\u7559pid\u4e0d\u4e3a\u7a7a\u7684\u884c\u3002\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b sql \u67e5\u8be2\uff1a<\/p>\n<pre>DELETE FROM datas \nWHERE pid IS NULL AND (credit, company, name, phone, id, rootid) IN (\n    SELECT credit, company, name, phone, id, rootid \n    FROM datas \n    WHERE pid IS NOT NULL\n);<\/pre>\n<p>  \u767b\u5f55\u540e\u590d\u5236   <\/p>\n<p>\u6b64\u67e5\u8be2\u5c06\u5220\u9664datas\u8868\u4e2dpid\u5b57\u6bb5\u4e3a\u7a7a\u4e14credit\u3001company\u3001name\u3001phone\u3001id\u548crootid\u5b57\u6bb5\u503c\u4e0epid\u4e0d\u4e3a\u7a7a\u7684\u884c\u76f8\u540c\u7684\u884c\u3002<\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u5220\u9664\u6570\u636e\u5e93\u4e2d\u7279\u5b9a\u5b57\u6bb5\u76f8\u540c\u4f46\u7279\u5b9a\u5217\u503c\u4e3a\u7a7a\u7684\u884c\uff1f\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5982\u4f55\u5220\u9664\u6570\u636e\u5e93\u4e2d\u7279\u5b9a\u5b57\u6bb5\u76f8\u540c\u4f46\u7279\u5b9a\u5217\u503c\u4e3a\u7a7a\u7684\u884c \u6570\u636e\u5e93\u4e2d\u7684\u8868\u901a\u5e38\u5305\u542b\u591a\u4e2a\u5b57\u6bb5\u3002\u5982\u679c\u67d0\u4e2a\u5b57\u6bb5\u503c\u4e3a\u7a7a\uff0c\u800c\u5176\u4ed6\u5b57\u6bb5\u503c\u76f8\u540c\uff0c\u5219\u53ef\u80fd\u9700\u8981\u5220\u9664\u8fd9\u4e9b\u7a7a\u503c\u884c\uff0c\u4ee5\u4fdd\u6301\u6570\u636e\u7684\u5b8c\u6574\u6027\u3002 \u5728\u63d0\u4f9b\u7684\u793a\u4f8b\u4e2d\uff0cdatas\u8868\u4e2d\u6709\u4ee5\u4e0b\u6570\u636e\uff1a credit company name phone id pid 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u5f20\u4e09 3930 21d4f7 null 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u5f20\u4e09 3930 21d4f7 6ec897 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u738b\u4e94 1895 2c6dcd 21d4f7 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u738b\u4e94 1895 a8c70b 21d4f7 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u674e\u56db 9894 33db09 21d4f7 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u674e\u56db 9894 703e16 null 99284 \u4f20\u5a92\u6709\u9650\u516c\u53f8 \u674e\u56db 9894 0faa54 21d4f7 \u76ee\u6807\u662f\u5220\u9664pid\u4e3a\u7a7a\u7684name\u4e3a\u5f20\u4e09\u7684\u884c\uff0c\u540c\u65f6\u4fdd\u7559pid\u4e0d\u4e3a\u7a7a\u7684\u884c\u3002\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b sql \u67e5\u8be2\uff1a DELETE [&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-26903","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/26903","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=26903"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/26903\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=26903"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=26903"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=26903"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}