{"id":2752,"date":"2018-05-05T15:33:17","date_gmt":"2018-05-05T07:33:17","guid":{"rendered":"http:\/\/www.xttblog.com\/?p=2752"},"modified":"2018-05-05T15:33:17","modified_gmt":"2018-05-05T07:33:17","slug":"%e7%bb%99postgresql%e6%95%b0%e6%8d%ae%e5%ba%93%e7%9a%84%e8%a1%a8%e5%92%8c%e5%88%97%e6%b7%bb%e5%8a%a0%e6%b3%a8%e9%87%8a%ef%bc%88comment%ef%bc%89","status":"publish","type":"post","link":"https:\/\/www.xttblog.com\/?p=2752","title":{"rendered":"\u7ed9postgresql\u6570\u636e\u5e93\u7684\u8868\u548c\u5217\u6dfb\u52a0\u6ce8\u91ca\uff08comment\uff09"},"content":{"rendered":"<p>\n\tpostgresql \u6570\u636e\u5e93\u56fd\u5185\u7528\u7684\u4eba\u5e76\u4e0d\u662f\u5f88\u591a\uff0c\u800c\u4e00\u4e9b\u8001\u9879\u76ee\u91c7\u7528\u4e86\u8fd9\u4e2a\u6570\u636e\u5e93\u3002\u7ef4\u62a4\u8d77\u6765\u7279\u522b\u9ebb\u70e6\uff0c\u56e0\u4e3a\u56fd\u5185\u7528\u7684\u4eba\u6bd4\u8f83\u5c11\uff0c\u76f8\u5173\u8d44\u6599\u4e5f\u5f88\u5c11\u3002\n<\/p>\n<p>\n\t\u53e6\u5916\u8fd8\u6709\u4e00\u4e9b\u51fd\u6570\uff0cpostgresql \u4e5f\u6ca1\u6709\u5bf9\u5e94\u7684\u63d0\u4f9b\u3002\u8fd8\u6709\u5bf9\u4e8e\u8868\u5206\u533a\uff0c\u4f4e\u7248\u672c\u7684&nbsp;postgresql \u6570\u636e\u5e93\u6839\u672c\u90fd\u6ca1\u6709\u8fd9\u4e2a\u529f\u80fd\uff0c\u4e0d\u652f\u6301\u3002\u9700\u8981\u81ea\u5df1\u81ea\u52a8\u7684\u521b\u5efa\u8868\u8fdb\u884c\u5206\u533a\u3002\n<\/p>\n<p>\n\t\u603b\u4e4b&nbsp;postgresql \u6570\u636e\u5e93\u7528\u8d77\u6765\u5b9e\u5728\u662f\u592a\u8fc7\u9ebb\u70e6\uff0c\u672c\u6587\u603b\u7ed3\u4e86\u4e00\u4e9b\u7ed9&nbsp;postgresql \u6570\u636e\u5e93\u7684\u8868\u548c\u5217\u6dfb\u52a0\u6ce8\u91ca\u7684\u65b9\u6cd5\uff0c\u65b9\u4fbf\u5df2\u7ecf\u91c7\u7528&nbsp;postgresql \u6570\u636e\u5e93\u800c\u4e0d\u5f97\u4e0d\u7528\u7684\u7a0b\u5e8f\u5458\u3002\n<\/p>\n<p>\n\t\u9996\u5148\u8bf4\u7ed9\u8868\u6dfb\u52a0\u6ce8\u91ca\uff1a\n<\/p>\n<pre class=\"brush:sql;\">\r\ncomment on table xttblog is &#039;\u4e1a\u4f59\u8349&#039;;<\/pre>\n<p>\n\t\u5176\u4e2d xttblog \u662f\u8868\u540d\uff0c\u6dfb\u52a0\u7684\u6ce8\u91ca\u662f&ldquo;\u4e1a\u4f59\u8349&rdquo;\u3002\n<\/p>\n<p>\n\t\u7ed9\u5217\u6dfb\u52a0\u6ce8\u91ca\u7684\u65b9\u6cd5\u5982\u4e0b\uff1a\n<\/p>\n<pre class=\"brush:sql;\">\r\ncreate table xttblog(id int not null, url_id int); \r\ncomment on column xttblog.id is &#039;\u4e3b\u952eID\uff0c\u81ea\u589e&#039;;<\/pre>\n<p>\n\t\u6ce8\u610f\u521b\u5efa\u8868\u7684\u65f6\u5019\uff0c\u4e0d\u80fd\u518d\u5217\u540e\u9762\u52a0&nbsp;comment \u3002\u6dfb\u52a0\u540e\u6267\u884c\u4f1a\u62a5\u9519\uff0c\u56e0\u4e3a\u8fd9\u662f MySQL\uff0cOracle\u7684\u7528\u6cd5\uff0c\u4e0d\u662f Postgresql \u7684\u7528\u6cd5\u3002\n<\/p>\n<p>\n\t\u4e0b\u9762\u518d\u8bf4\u8bf4\u5982\u4f55\u67e5\u8be2\u8868\u4e2d\u7684\u6ce8\u91ca\u3002sql \u8bed\u53e5\u5982\u4e0b\uff1a\n<\/p>\n<pre class=\"brush:sql;\">\r\nselect description from pg_descriptionjoin pg_class on pg_description.objoid = pg_class.oid where relname = &#039;xttblog&#039;<\/pre>\n<p>\n\t\u5176\u4e2d\u4ee5 pg_ \u5f00\u5934\u7684\u8868\u90fd\u662f Postgresql \u6570\u636e\u5e93\u7684\u7cfb\u7edf\u8868\u3002\u7cfb\u7edf\u8868\u4e2d\u5b58\u50a8\u7740\u5f88\u591a\u4e0e\u8868\u548c\u914d\u7f6e\u76f8\u5173\u7684\u4fe1\u606f\u3002\n<\/p>\n<p>\n\tPostgreSQL \u83b7\u53d6\u6570\u636e\u8868\u7684\u6ce8\u91ca\u4fe1\u606f\u548c\u8868\u4e2d\u5b57\u6bb5\u7684\u6ce8\u91ca\u4fe1\u606f\u548c\u4e0a\u9762\u7684 SQL \u7c7b\u4f3c\u3002\n<\/p>\n<p>\n\t\u548c\u8868\u76f8\u5173\u7684\u4fe1\u606f\u90fd\u5728 pg_description \u8fd9\u4e2a\u8868\u4e2d\uff0c\u67e5 pg_description \u8fd9\u4e2a\u7cfb\u7edf\u8868\uff0c\u91cc\u9762\u6709\u5b58\u8868\u548c\u5b57\u6bb5\u7684\u5907\u6ce8\u3002<\/p>\n<!-- <audio autoplay=\"autoplay\" height=\"100\" width=\"100\" hidden=\"true\"><source src=\"https:\/\/c.coka.la\/orAvPR.mp3\" type=\"audio\/mp3\"\/><\/audio><img decoding=\"async\" src=\"https:\/\/images.weserv.nl\/?url=https:\/\/ws3.sinaimg.cn\/large\/8fa5dcfcgy1g4em3rzar5j20ib089ae0.jpg\" alt=\"\u4e1a\u4f59\u8349\u516c\u4f17\u53f7\"\/> --><p><!-- <img decoding=\"async\" src=\"https:\/\/raw.githubusercontent.com\/xmt1139057136\/xttblog\/master\/8fa5dcfcgy1g4em3rzar5j20ib089ae0.jpg\" alt=\"\u4e1a\u4f59\u8349\u516c\u4f17\u53f7\"\/>--><img decoding=\"async\" src=\"https:\/\/saas.51autoparts.cn\/api\/admin\/sys-file\/oss\/file?fileName=84db51f8561e448f9a4fda2eff0811f9.jpg\" alt=\"\u4e1a\u4f59\u8349\u516c\u4f17\u53f7\"\/><\/p><p>\u6700\u540e\uff0c\u6b22\u8fce\u5173\u6ce8\u6211\u7684\u4e2a\u4eba\u5fae\u4fe1\u516c\u4f17\u53f7\uff1a\u4e1a\u4f59\u8349\uff08yyucao\uff09\uff01<b>\u53ef\u52a0\u4f5c\u8005\u5fae\u4fe1\u53f7\uff1a<font color=\"red\">xttblog2<\/font>\u3002\u5907\u6ce8\uff1a\u201c1\u201d\uff0c\u6dfb\u52a0\u535a\u4e3b\u5fae\u4fe1\u62c9\u4f60\u8fdb\u5fae\u4fe1\u7fa4\u3002\u5907\u6ce8\u9519\u8bef\u4e0d\u4f1a\u540c\u610f\u597d\u53cb\u7533\u8bf7\u3002<\/b>\u518d\u6b21\u611f\u8c22\u60a8\u7684\u5173\u6ce8\uff01\u540e\u7eed\u6709\u7cbe\u5f69\u5185\u5bb9\u4f1a\u7b2c\u4e00\u65f6\u95f4\u53d1\u7ed9\u60a8\uff01\u539f\u521b\u6587\u7ae0\u6295\u7a3f\u8bf7\u53d1\u9001\u81f3532009913@qq.com\u90ae\u7bb1\u3002\u5546\u52a1\u5408\u4f5c\u4e5f\u53ef\u6dfb\u52a0\u4f5c\u8005\u5fae\u4fe1\u8fdb\u884c\u8054\u7cfb\uff01<\/p><p>\u672c\u6587\u539f\u6587\u51fa\u5904\uff1a<a href=\"https:\/\/www.xttblog.com\">\u4e1a\u4f59\u8349<\/a>\uff1a &raquo; <a href=\"https:\/\/www.xttblog.com\/?p=2752\">\u7ed9postgresql\u6570\u636e\u5e93\u7684\u8868\u548c\u5217\u6dfb\u52a0\u6ce8\u91ca\uff08comment\uff09<\/a><\/p><!-- <div class=\"bd-reward-stl\"><button id=\"bdRewardBtn\"><span><\/span><\/button><\/div> -->","protected":false},"excerpt":{"rendered":"<p>postgresql \u6570\u636e\u5e93\u56fd\u5185\u7528\u7684\u4eba\u5e76\u4e0d\u662f\u5f88\u591a\uff0c\u800c\u4e00\u4e9b\u8001\u9879\u76ee\u91c7\u7528\u4e86\u8fd9\u4e2a\u6570\u636e\u5e93\u3002\u7ef4\u62a4\u8d77\u6765\u7279\u522b\u9ebb\u70e6\uff0c\u56e0\u4e3a\u56fd\u5185\u7528\u7684 [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12],"tags":[428,83,467,429,747],"class_list":["post-2752","post","type-post","status-publish","format-standard","hentry","category-sql","tag-greenplum","tag-mysql","tag-oracle","tag-postgresql","tag-747"],"_links":{"self":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts\/2752","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2752"}],"version-history":[{"count":1,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts\/2752\/revisions"}],"predecessor-version":[{"id":2753,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts\/2752\/revisions\/2753"}],"wp:attachment":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2752"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2752"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2752"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}