\u547d\u4ee4<\/a>\u548c\u8bed\u6cd5\uff0c\u56e0\u6b64\u9700\u8981\u9488\u5bf9\u6027\u5730\u8fdb\u884c\u5b66\u4e60\u548c\u64cd\u4f5c\u3002<\/p>\n\u5b89\u88c5\u6570\u636e\u5e93\u5ba2\u6237\u7aef<\/p>\n
\u5728Linux\u670d\u52a1\u5668\u4e0a\u8981\u67e5\u8be2\u6570\u636e\u5e93\uff0c\u9700\u8981\u5b89\u88c5\u76f8\u5e94\u7684\u5ba2\u6237\u7aef\u8f6f\u4ef6\u3002\u5e38\u89c1\u7684MySQL\u5ba2\u6237\u7aef\u6709mysql\u3001mysql-workbench\u7b49\uff0cOracle\u5ba2\u6237\u7aef\u6709sqlplus\u7b49\u3002\u5b89\u88c5\u65b9\u6cd5\u53ef\u4ee5\u901a\u8fc7\u641c\u7d22\u5f15\u64ce\u6216\u8005\u76f8\u5173\u6587\u6863\u8fdb\u884c\u5b66\u4e60\u3002<\/p>\n
\u8fde\u63a5\u6570\u636e\u5e93<\/p>\n
\u5b89\u88c5\u597d\u5ba2\u6237\u7aef\u4e4b\u540e\u6df1\u5ea6linux\u7cfb\u7edf\uff0c\u9700\u8981\u8fde\u63a5\u5230\u6307\u5b9a\u7684\u6570\u636e\u5e93\u3002\u8fde\u63a5\u547d\u4ee4\u901a\u5e38\u5305\u62ec\u4e3b\u673a\u5730\u5740\u3001\u7528\u6237\u540d\u3001\u5bc6\u7801\u7b49\u53c2\u6570\u3002\u4f8b\u5982\uff0c\u5728MySQL\u4e2d\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u8fdb\u884c\u8fde\u63a5\uff1a<\/p>\n
\n
\nmysql -h hostname -u username -p\n<\/pre>\n<\/p>\n\u5176\u4e2dhostname\u662f\u4e3b\u673a\u5730\u5740\uff0cusername\u662f\u7528\u6237\u540d\uff0c-p\u8868\u793a\u9700\u8981\u8f93\u5165\u5bc6\u7801\u3002<\/p>\n
\u663e\u793a\u6570\u636e\u5e93\u5217\u8868<\/p>\n
\u8fde\u63a5\u6210\u529f\u4e4b\u540e\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u663e\u793a\u5f53\u524d\u6240\u6709\u7684\u6570\u636e\u5e93\uff1a<\/p>\n
\n
\nshow databases;\n<\/pre>\n<\/p>\n<\/p>\n
\u5982\u679c\u60f3\u67e5\u770b\u67d0\u4e2a\u5177\u4f53\u7684\u6570\u636e\u5e93\u4e2d\u5305\u542b\u54ea\u4e9b\u8868\uff0c\u5219\u53ef\u4ee5\u5148\u9009\u62e9\u8be5\u5e93\u518d\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n
\n
\nuse database_name;\nshow tables;\n<\/pre>\n<\/p>\n\u521b\u5efa\u65b0\u6570\u636e\u5e93<\/p>\n
\u5982\u679c\u9700\u8981\u521b\u5efa\u4e00\u4e2a\u65b0\u7684\u6570\u636e\u5e93\uff0c\u5219\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n
\n
\ncreate database database_name;\n<\/pre>\n<\/p>\n\u5176\u4e2ddatabase_name\u4e3a\u8981\u521b\u5efa\u7684\u5e93\u540d\u3002<\/p>\n
\u663e\u793a\u8868\u5217\u8868<\/p>\n
\u8fde\u63a5\u5230\u6307\u5b9a\u5e93\u4e4b\u540elinux \u8bba\u575b\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u663e\u793a\u5f53\u524d\u5e93\u4e2d\u6240\u6709\u8868\u683c\uff1a<\/p>\n
\n
\nshow tables;\n<\/pre>\n<\/p>\n\u67e5\u8be2\u6570\u636e<\/p>\n
\u67e5\u8be2\u6570\u636e\u662f\u4f7f\u7528\u6700\u9891\u7e41\u7684\u64cd\u4f5c\u4e4b\u4e00\u3002\u5728MySQL\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528SELECT\u8bed\u53e5\u8fdb\u884c\u67e5\u8be2\u3002\u4f8b\u5982\uff1a<\/p>\n
\n
\nSELECT * FROM table_name WHERE condition;\n<\/pre>\n<\/p>\n\u5176\u4e2dtable_name\u8868\u793a\u8868\u540d\uff0ccondition\u8868\u793a\u67e5\u8be2\u6761\u4ef6\u3002\u8fd8\u53ef\u4ee5\u5bf9\u67e5\u8be2\u7ed3\u679c\u8fdb\u884c\u6392\u5e8f\u3001\u5206\u9875\u7b49\u8bbe\u7f6e\u3002<\/p>\n
\u66f4\u65b0\u6570\u636e<\/p>\n
\u66f4\u65b0\u6570\u636e\u901a\u5e38\u662f\u4e3a\u4e86\u4fee\u6539\u6216\u8005\u5220\u9664\u5df2\u6709\u8bb0\u5f55\u3002\u5728MySQL\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528UPDATE\u8bed\u53e5\u8fdb\u884c\u66f4\u65b0\u64cd\u4f5c\u3002\u4f8b\u5982\uff1a<\/p>\n
\n
\nUPDATE table_name SET column_name = new_value WHERE condition;\n<\/pre>\n<\/p>\n\u5176\u4e2dtable_name\u8868\u793a\u8868\u540d\uff0ccolumn_name\u8868\u793a\u8981\u4fee\u6539\u7684\u5217\u540d\uff0cnew_value\u4e3a\u65b0\u503c\uff0ccondition\u8868\u793a\u66f4\u65b0\u6761\u4ef6\u3002<\/p>\n
\u5220\u9664\u6570\u636e<\/p>\n
\u5220\u9664\u6570\u636e\u901a\u5e38\u662f\u4e3a\u4e86\u6e05\u9664\u65e0\u7528\u8bb0\u5f55\u6216\u8005\u9519\u8bef\u8bb0\u5f55\u3002\u5728MySQL\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528DELETE\u8bed\u53e5\u8fdb\u884c\u5220\u9664\u64cd\u4f5c\u3002\u4f8b\u5982\uff1a<\/p>\n
\n
\nDELETE FROM table_name WHERE condition;\n<\/pre>\n<\/p>\n\u5176\u4e2dtable_name\u8868\u793a\u8868\u540dlinux\u670d\u52a1\u5668\u67e5\u8be2\u6570\u636e\u5e93<\/strong>\uff0ccondition\u8868\u793a\u5220\u9664\u6761\u4ef6\u3002<\/p>\n\u603b\u7ed3<\/p>\n
\u901a\u8fc7\u4ee5\u4e0a\u4e5d\u4e2a\u65b9\u9762\u7684\u8ba8\u8bba\u548c\u64cd\u4f5c\u5b9e\u8df5\uff0c\u5728Linux\u670d\u52a1\u5668\u4e2d\u67e5\u8be2\u548c\u7ba1\u7406\u6570\u636e\u5e93\u5df2\u7ecf\u53d8\u5f97\u8f7b\u677e\u7b80\u5355\u8d77\u6765\u4e86\u3002\u4f46\u662f\u8fd9\u53ea\u662f\u57fa\u7840\u64cd\u4f5c\uff0c\u5728\u5b9e\u9645\u5e94\u7528\u573a\u666f\u4e2d\u8fd8\u9700\u8981\u66f4\u591a\u6df1\u5165\u548c\u9ad8\u7ea7\u7684\u6280\u80fd\u548c\u77e5\u8bc6\u652f\u6301\u3002\u56e0\u6b64\uff0c\u5728\u4eca\u540e\u5de5\u4f5c\u548c\u5b66\u4e60\u4e2d\u9700\u8981\u4e0d\u65ad\u79ef\u7d2f\u5e76\u63d0\u5347\u81ea\u5df1\u76f8\u5173\u6280\u80fd\u6c34\u5e73\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"
\u800c\u5728Linux\u670d\u52a1\u5668\u4e2d\uff0c\u67e5\u8be2\u6570\u636e\u5e93\u4e5f\u6210\u4e3a\u4e86\u4e00\u9879\u5fc5\u5907\u7684\u6280\u80fd\u3002\u672c\u6587\u5c06\u4ece\u4ee5\u4e0b\u4e5d\u4e2a\u65b9\u9762\u6765\u6df1\u5165\u63a2\u8ba8\u5982\u4f55\u5728Linux\u670d\u52a1\u5668\u4e0a\u67e5\u8be2\u6570\u636e\u5e93\uff1a1.\u4e0d\u540c\u7684\u6570\u636e\u5e93\u7c7b\u578b\u4f1a\u6709\u4e0d\u540c\u7684\u547d\u4ee4\u548c\u8bed\u6cd5\uff0c\u56e0\u6b64\u9700\u8981\u9488\u5bf9\u6027\u5730\u8fdb\u884c\u5b66\u4e60\u548c\u64cd\u4f5c\u3002\u5728Linux\u670d\u52a1\u5668\u4e0a\u8981\u67e5\u8be2\u6570\u636e\u5e93\uff0c\u9700\u8981\u5b89\u88c5\u76f8\u5e94\u7684\u5ba2\u6237\u7aef\u8f6f\u4ef6\u3002\u901a\u8fc7\u4ee5\u4e0a\u4e5d\u4e2a\u65b9\u9762\u7684\u8ba8\u8bba\u548c\u64cd\u4f5c\u5b9e\u8df5\uff0c\u5728Linux\u670d\u52a1\u5668\u4e2d\u67e5\u8be2\u548c\u7ba1\u7406\u6570\u636e\u5e93\u5df2\u7ecf\u53d8\u5f97\u8f7b\u677e\u7b80\u5355\u8d77\u6765\u4e86\u3002<\/p>\n","protected":false},"author":1,"featured_media":267750,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[988],"tags":[999],"class_list":["post-267749","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tougao","tag-999"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/267749","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=267749"}],"version-history":[{"count":0,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/267749\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/267750"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=267749"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=267749"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=267749"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}