{"id":166033,"date":"2024-11-05T15:10:34","date_gmt":"2024-11-05T07:10:34","guid":{"rendered":"https:\/\/server.hk\/cnblog\/166033\/"},"modified":"2024-11-05T15:10:35","modified_gmt":"2024-11-05T07:10:35","slug":"%e5%bf%ab%e9%80%9f%e9%96%8b%e7%99%bc%e6%95%b8%e6%93%9a%e5%ba%ab%ef%bc%8c%e4%ba%ab%e5%8f%97%e9%ab%98%e6%95%88%e6%93%8d%e4%bd%9c-%e6%95%b8%e6%93%9a%e5%ba%ab%e9%96%8b%e7%99%bc%e5%b7%a5","status":"publish","type":"post","link":"https:\/\/server.hk\/cnblog\/166033\/","title":{"rendered":"\u5feb\u901f\u958b\u767c\u6578\u64da\u5eab\uff0c\u4eab\u53d7\u9ad8\u6548\u64cd\u4f5c\u2014\u2014\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177\u63a8\u85a6 (\u5feb\u901f\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177)"},"content":{"rendered":"<h1 id=\"%e5%bf%ab%e9%80%9f%e9%96%8b%e7%99%bc%e6%95%b8%e6%93%9a%e5%ba%ab%ef%bc%8c%e4%ba%ab%e5%8f%97%e9%ab%98%e6%95%88%e6%93%8d%e4%bd%9c-%e6%95%b8%e6%93%9a%e5%ba%ab%e9%96%8b%e7%99%bc%e5%b7%a5-bPvdaTfiuF\">\u5feb\u901f\u958b\u767c\u6578\u64da\u5eab\uff0c\u4eab\u53d7\u9ad8\u6548\u64cd\u4f5c\u2014\u2014\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177\u63a8\u85a6<\/h1>\n<p>\u5728\u7576\u4eca\u6578\u64da\u9a45\u52d5\u7684\u4e16\u754c\u4e2d\uff0c\u6578\u64da\u5eab\u7684\u958b\u767c\u548c\u7ba1\u7406\u8b8a\u5f97\u8d8a\u4f86\u8d8a\u91cd\u8981\u3002\u7121\u8ad6\u662f\u4f01\u696d\u9084\u662f\u500b\u4eba\u958b\u767c\u8005\uff0c\u9078\u64c7\u5408\u9069\u7684\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177\u90fd\u80fd\u986f\u8457\u63d0\u9ad8\u5de5\u4f5c\u6548\u7387\u3002\u672c\u6587\u5c07\u4ecb\u7d39\u4e00\u4e9b\u6d41\u884c\u7684\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177\uff0c\u5e6b\u52a9\u958b\u767c\u8005\u5feb\u901f\u69cb\u5efa\u548c\u7ba1\u7406\u6578\u64da\u5eab\u3002<\/p>\n<h2 id=\"1-mysql-workbench-bPvdaTfiuF\">1. MySQL Workbench<\/h2>\n<p>MySQL Workbench \u662f\u4e00\u6b3e\u529f\u80fd\u5f37\u5927\u7684\u6578\u64da\u5eab\u8a2d\u8a08\u548c\u7ba1\u7406\u5de5\u5177\uff0c\u5c08\u70ba MySQL \u6578\u64da\u5eab\u800c\u8a2d\u8a08\u3002\u5b83\u63d0\u4f9b\u4e86\u53ef\u8996\u5316\u7684\u6578\u64da\u5eab\u8a2d\u8a08\u754c\u9762\uff0c\u8b93\u958b\u767c\u8005\u80fd\u5920\u8f15\u9b06\u5730\u5275\u5efa\u548c\u4fee\u6539\u6578\u64da\u5eab\u7d50\u69cb\u3002<\/p>\n<ul>\n<li><strong>\u7279\u9ede\uff1a<\/strong>\u652f\u6301\u6578\u64da\u5efa\u6a21\u3001SQL \u958b\u767c\u3001\u4f3a\u670d\u5668\u7ba1\u7406\u7b49\u529f\u80fd\u3002<\/li>\n<li><strong>\u512a\u52e2\uff1a<\/strong>\u53ef\u8996\u5316\u754c\u9762\u4f7f\u5f97\u6578\u64da\u5eab\u8a2d\u8a08\u8b8a\u5f97\u76f4\u89c0\uff0c\u4e26\u4e14\u652f\u6301\u591a\u7a2e\u64cd\u4f5c\u7cfb\u7d71\u3002<\/li>\n<\/ul>\n<pre><code>-- \u5275\u5efa\u4e00\u500b\u65b0\u7684\u6578\u64da\u5eab\nCREATE DATABASE my_database;\n<\/code><\/pre>\n<h2 id=\"2-dbeaver-bPvdaTfiuF\">2. DBeaver<\/h2>\n<p>DBeaver \u662f\u4e00\u6b3e\u958b\u6e90\u7684\u6578\u64da\u5eab\u7ba1\u7406\u5de5\u5177\uff0c\u652f\u6301\u591a\u7a2e\u6578\u64da\u5eab\u7cfb\u7d71\uff0c\u5305\u62ec MySQL\u3001PostgreSQL\u3001SQLite \u7b49\u3002\u5b83\u7684\u754c\u9762\u53cb\u597d\uff0c\u9069\u5408\u5404\u7a2e\u6c34\u5e73\u7684\u958b\u767c\u8005\u4f7f\u7528\u3002<\/p>\n<ul>\n<li><strong>\u7279\u9ede\uff1a<\/strong>\u652f\u6301 SQL \u7de8\u8f2f\u3001\u6578\u64da\u5c0e\u5165\u5c0e\u51fa\u3001\u6578\u64da\u53ef\u8996\u5316\u7b49\u529f\u80fd\u3002<\/li>\n<li><strong>\u512a\u52e2\uff1a<\/strong>\u8de8\u5e73\u53f0\u652f\u6301\uff0c\u4e26\u4e14\u64c1\u6709\u8c50\u5bcc\u7684\u63d2\u4ef6\u751f\u614b\u7cfb\u7d71\u3002<\/li>\n<\/ul>\n<pre><code>-- \u67e5\u8a62\u6578\u64da\nSELECT * FROM users WHERE age &gt; 18;\n<\/code><\/pre>\n<h2 id=\"3-microsoft-sql-server-management-studio-ssms-bPvdaTfiuF\">3. Microsoft SQL Server Management Studio (SSMS)<\/h2>\n<p>SSMS \u662f\u5fae\u8edf\u63d0\u4f9b\u7684\u4e00\u6b3e\u5c08\u696d\u7684 SQL Server \u7ba1\u7406\u5de5\u5177\uff0c\u9069\u5408\u9700\u8981\u4f7f\u7528 SQL Server \u7684\u958b\u767c\u8005\u3002\u5b83\u63d0\u4f9b\u4e86\u5f37\u5927\u7684\u67e5\u8a62\u7de8\u8f2f\u5668\u548c\u6578\u64da\u5eab\u7ba1\u7406\u529f\u80fd\u3002<\/p>\n<ul>\n<li><strong>\u7279\u9ede\uff1a<\/strong>\u652f\u6301\u6578\u64da\u5eab\u8a2d\u8a08\u3001\u67e5\u8a62\u7de8\u8f2f\u3001\u6027\u80fd\u76e3\u63a7\u7b49\u529f\u80fd\u3002<\/li>\n<li><strong>\u512a\u52e2\uff1a<\/strong>\u8207 SQL Server \u7684\u6df1\u5ea6\u96c6\u6210\uff0c\u63d0\u4f9b\u4e86\u8c50\u5bcc\u7684\u7ba1\u7406\u9078\u9805\u3002<\/li>\n<\/ul>\n<pre><code>-- \u5275\u5efa\u4e00\u500b\u8868\nCREATE TABLE Employees (\n    ID INT PRIMARY KEY,\n    Name NVARCHAR(100),\n    Age INT\n);\n<\/code><\/pre>\n<h2 id=\"4-navicat-bPvdaTfiuF\">4. Navicat<\/h2>\n<p>Navicat \u662f\u4e00\u6b3e\u5546\u696d\u6578\u64da\u5eab\u7ba1\u7406\u5de5\u5177\uff0c\u652f\u6301\u591a\u7a2e\u6578\u64da\u5eab\u7cfb\u7d71\uff0c\u5305\u62ec MySQL\u3001PostgreSQL\u3001Oracle \u7b49\u3002\u5b83\u63d0\u4f9b\u4e86\u76f4\u89c0\u7684\u7528\u6236\u754c\u9762\u548c\u5f37\u5927\u7684\u529f\u80fd\u3002<\/p>\n<ul>\n<li><strong>\u7279\u9ede\uff1a<\/strong>\u652f\u6301\u6578\u64da\u540c\u6b65\u3001\u5831\u544a\u751f\u6210\u3001\u6578\u64da\u5099\u4efd\u7b49\u529f\u80fd\u3002<\/li>\n<li><strong>\u512a\u52e2\uff1a<\/strong>\u7528\u6236\u53cb\u597d\u7684\u754c\u9762\u548c\u5f37\u5927\u7684\u529f\u80fd\u7d44\u5408\uff0c\u9069\u5408\u5c08\u696d\u958b\u767c\u8005\u4f7f\u7528\u3002<\/li>\n<\/ul>\n<pre><code>-- \u6578\u64da\u5099\u4efd\nBACKUP DATABASE my_database TO DISK = 'C:backupmy_database.bak';\n<\/code><\/pre>\n<h2 id=\"5-heidisql-bPvdaTfiuF\">5. HeidiSQL<\/h2>\n<p>HeidiSQL \u662f\u4e00\u6b3e\u8f15\u91cf\u7d1a\u7684\u6578\u64da\u5eab\u7ba1\u7406\u5de5\u5177\uff0c\u4e3b\u8981\u7528\u65bc MySQL \u548c MariaDB\u3002\u5b83\u7684\u754c\u9762\u7c21\u6f54\uff0c\u64cd\u4f5c\u7c21\u55ae\uff0c\u975e\u5e38\u9069\u5408\u521d\u5b78\u8005\u4f7f\u7528\u3002<\/p>\n<ul>\n<li><strong>\u7279\u9ede\uff1a<\/strong>\u652f\u6301\u6279\u91cf\u6578\u64da\u7de8\u8f2f\u3001\u6578\u64da\u5c0e\u5165\u5c0e\u51fa\u7b49\u529f\u80fd\u3002<\/li>\n<li><strong>\u512a\u52e2\uff1a<\/strong>\u514d\u8cbb\u958b\u6e90\uff0c\u4e26\u4e14\u652f\u6301\u591a\u7a2e\u8a9e\u8a00\u3002<\/li>\n<\/ul>\n<pre><code>-- \u63d2\u5165\u6578\u64da\nINSERT INTO users (Name, Age) VALUES ('Alice', 30);\n<\/code><\/pre>\n<h2 id=\"%e7%b8%bd%e7%b5%90-bPvdaTfiuF\">\u7e3d\u7d50<\/h2>\n<p>\u9078\u64c7\u5408\u9069\u7684\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177\u5c0d\u65bc\u63d0\u9ad8\u958b\u767c\u6548\u7387\u81f3\u95dc\u91cd\u8981\u3002\u7121\u8ad6\u662f MySQL Workbench\u3001DBeaver\u3001SSMS\u3001Navicat \u9084\u662f HeidiSQL\uff0c\u6bcf\u6b3e\u5de5\u5177\u90fd\u6709\u5176\u7368\u7279\u7684\u512a\u52e2\u548c\u9069\u7528\u5834\u666f\u3002\u958b\u767c\u8005\u53ef\u4ee5\u6839\u64da\u81ea\u5df1\u7684\u9700\u6c42\u9078\u64c7\u6700\u5408\u9069\u7684\u5de5\u5177\uff0c\u5f9e\u800c\u5feb\u901f\u958b\u767c\u6578\u64da\u5eab\uff0c\u4eab\u53d7\u9ad8\u6548\u64cd\u4f5c\u3002<\/p>\n<p>\u5982\u679c\u60a8\u6b63\u5728\u5c0b\u627e\u9ad8\u6548\u7684 <a href=\"https:\/\/server.hk\">VPS<\/a> \u89e3\u6c7a\u65b9\u6848\u4f86\u652f\u6301\u60a8\u7684\u6578\u64da\u5eab\u958b\u767c\uff0cServer.HK \u63d0\u4f9b\u591a\u7a2e\u9078\u64c7\uff0c\u6eff\u8db3\u4e0d\u540c\u9700\u6c42\u7684\u7528\u6236\u3002\u7121\u8ad6\u662f <a href=\"https:\/\/server.hk\">\u9999\u6e2fVPS<\/a> \u9084\u662f\u5176\u4ed6\u670d\u52d9\uff0c\u6211\u5011\u90fd\u80fd\u70ba\u60a8\u63d0\u4f9b\u7a69\u5b9a\u53ef\u9760\u7684\u652f\u6301\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5feb\u901f\u958b\u767c\u6578\u64da\u5eab\uff0c\u63d0\u5347\u64cd\u4f5c\u6548\u7387\uff01\u63a2\u7d22\u6700\u4f73\u6578\u64da\u5eab\u958b\u767c\u5de5\u5177\uff0c\u52a9\u60a8\u8f15\u9b06\u7ba1\u7406\u548c\u512a\u5316\u6578\u64da\u5eab\u6027\u80fd\u3002<\/p>\n","protected":false},"author":0,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[101],"tags":[],"class_list":["post-166033","post","type-post","status-publish","format-standard","hentry","category-database"],"_links":{"self":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/166033","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/comments?post=166033"}],"version-history":[{"count":1,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/166033\/revisions"}],"predecessor-version":[{"id":166034,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/166033\/revisions\/166034"}],"wp:attachment":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/media?parent=166033"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/categories?post=166033"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/tags?post=166033"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}