{"id":129363,"date":"2024-10-26T21:04:28","date_gmt":"2024-10-26T13:04:28","guid":{"rendered":"https:\/\/server.hk\/cnblog\/129363\/"},"modified":"2024-10-26T21:04:29","modified_gmt":"2024-10-26T13:04:29","slug":"ora-14031-%e5%88%86%e5%8d%80%e5%88%97%e4%b8%8d%e5%be%97%e7%82%ba-long-%e6%88%96-long-raw-%e9%a1%9e%e5%9e%8b%e3%80%82oracle-%e5%a0%b1%e9%8c%af-%e6%95%85%e9%9a%9c%e4%bf%ae%e5%be%a9-%e9%81%a0%e7%a8%8b","status":"publish","type":"post","link":"https:\/\/server.hk\/cnblog\/129363\/","title":{"rendered":"ORA-14031: \u5206\u5340\u5217\u4e0d\u5f97\u70ba LONG \u6216 LONG RAW \u985e\u578b\u3002ORACLE \u5831\u932f \u6545\u969c\u4fee\u5fa9 \u9060\u7a0b\u8655\u7406"},"content":{"rendered":"<h1 id=\"ora-14031-%e5%88%86%e5%8d%80%e5%88%97%e4%b8%8d%e5%be%97%e7%82%ba-long-%e6%88%96-long-raw-%e9%a1%9e%e5%9e%8b-kWxKjOedIV\">ORA-14031: \u5206\u5340\u5217\u4e0d\u5f97\u70ba LONG \u6216 LONG RAW \u985e\u578b<\/h1>\n<p>\u5728\u4f7f\u7528 Oracle \u6578\u64da\u5eab\u6642\uff0c\u958b\u767c\u8005\u548c\u6578\u64da\u5eab\u7ba1\u7406\u54e1\u53ef\u80fd\u6703\u9047\u5230\u5404\u7a2e\u932f\u8aa4\u4ee3\u78bc\uff0c\u5176\u4e2d\u4e4b\u4e00\u4fbf\u662f ORA-14031\u3002\u9019\u500b\u932f\u8aa4\u901a\u5e38\u51fa\u73fe\u5728\u5617\u8a66\u5c07 LONG \u6216 LONG RAW \u985e\u578b\u7684\u5217\u6dfb\u52a0\u5230\u5206\u5340\u8868\u6642\u3002\u672c\u6587\u5c07\u6df1\u5165\u63a2\u8a0e\u9019\u500b\u932f\u8aa4\u7684\u539f\u56e0\u3001\u5f71\u97ff\u4ee5\u53ca\u5982\u4f55\u9032\u884c\u6545\u969c\u4fee\u5fa9\u3002<\/p>\n<h2 id=\"ora-14031-%e9%8c%af%e8%aa%a4%e7%9a%84%e5%8e%9f%e5%9b%a0-kWxKjOedIV\">ORA-14031 \u932f\u8aa4\u7684\u539f\u56e0<\/h2>\n<p>ORA-14031 \u932f\u8aa4\u7684\u4e3b\u8981\u539f\u56e0\u662f Oracle \u6578\u64da\u5eab\u4e0d\u5141\u8a31\u5728\u5206\u5340\u8868\u4e2d\u4f7f\u7528 LONG \u6216 LONG RAW \u985e\u578b\u7684\u5217\u3002\u9019\u662f\u56e0\u70ba\u9019\u4e9b\u6578\u64da\u985e\u578b\u7684\u8a2d\u8a08\u521d\u8877\u662f\u7528\u65bc\u5b58\u5132\u5927\u91cf\u7684\u4e8c\u9032\u5236\u6578\u64da\u6216\u5b57\u7b26\u6578\u64da\uff0c\u800c\u5206\u5340\u8868\u7684\u8a2d\u8a08\u5247\u662f\u70ba\u4e86\u63d0\u9ad8\u67e5\u8a62\u6027\u80fd\u548c\u6578\u64da\u7ba1\u7406\u7684\u9748\u6d3b\u6027\u3002<\/p>\n<p>\u5177\u9ad4\u4f86\u8aaa\uff0cLONG \u548c LONG RAW \u985e\u578b\u7684\u5217\u5728\u6578\u64da\u5eab\u4e2d\u6709\u4ee5\u4e0b\u7279\u9ede\uff1a<\/p>\n<ul>\n<li>\u4e0d\u652f\u6301\u5206\u5340\uff1a\u9019\u4e9b\u6578\u64da\u985e\u578b\u4e0d\u652f\u6301\u5728\u5206\u5340\u8868\u4e2d\u4f7f\u7528\uff0c\u56e0\u70ba\u5b83\u5011\u7684\u5b58\u5132\u65b9\u5f0f\u8207\u5206\u5340\u7684\u8a2d\u8a08\u4e0d\u517c\u5bb9\u3002<\/li>\n<li>\u9650\u5236\u6027\u64cd\u4f5c\uff1a\u5c0d\u65bc\u9019\u4e9b\u985e\u578b\u7684\u5217\uff0c\u67d0\u4e9b\u64cd\u4f5c\uff08\u5982\u7d22\u5f15\u3001\u7d04\u675f\u7b49\uff09\u53d7\u5230\u9650\u5236\uff0c\u9019\u4f7f\u5f97\u5b83\u5011\u5728\u5206\u5340\u8868\u4e2d\u4e0d\u5177\u5099\u9748\u6d3b\u6027\u3002<\/li>\n<\/ul>\n<h2 id=\"%e5%a6%82%e4%bd%95%e4%bf%ae%e5%be%a9-ora-14031-%e9%8c%af%e8%aa%a4-kWxKjOedIV\">\u5982\u4f55\u4fee\u5fa9 ORA-14031 \u932f\u8aa4<\/h2>\n<p>\u7576\u9047\u5230 ORA-14031 \u932f\u8aa4\u6642\uff0c\u958b\u767c\u8005\u53ef\u4ee5\u63a1\u53d6\u4ee5\u4e0b\u5e7e\u500b\u6b65\u9a5f\u4f86\u9032\u884c\u6545\u969c\u4fee\u5fa9\uff1a<\/p>\n<h3 id=\"1-%e6%aa%a2%e6%9f%a5%e6%95%b8%e6%93%9a%e9%a1%9e%e5%9e%8b-kWxKjOedIV\">1. \u6aa2\u67e5\u6578\u64da\u985e\u578b<\/h3>\n<p>\u9996\u5148\uff0c\u6aa2\u67e5\u60a8\u5617\u8a66\u6dfb\u52a0\u5230\u5206\u5340\u8868\u4e2d\u7684\u5217\u7684\u6578\u64da\u985e\u578b\u3002\u5982\u679c\u767c\u73fe\u4f7f\u7528\u4e86 LONG \u6216 LONG RAW \u985e\u578b\uff0c\u5247\u9700\u8981\u8003\u616e\u5c07\u5176\u66f4\u6539\u70ba\u5176\u4ed6\u652f\u6301\u7684\u6578\u64da\u985e\u578b\uff0c\u4f8b\u5982 CLOB \u6216 BLOB\u3002<\/p>\n<pre><code>-- \u793a\u4f8b\uff1a\u5c07 LONG \u5217\u66f4\u6539\u70ba CLOB\nALTER TABLE your_partitioned_table\nMODIFY your_long_column CLOB;\n<\/code><\/pre>\n<h3 id=\"2-%e4%bd%bf%e7%94%a8-clob-%e6%88%96-blob-kWxKjOedIV\">2. \u4f7f\u7528 CLOB \u6216 BLOB<\/h3>\n<p>\u5982\u4e0a\u6240\u8ff0\uff0cCLOB\uff08Character Large Object\uff09\u548c BLOB\uff08Binary Large Object\uff09\u662f\u66f4\u9069\u5408\u7528\u65bc\u5206\u5340\u8868\u7684\u6578\u64da\u985e\u578b\u3002\u9019\u4e9b\u985e\u578b\u4e0d\u50c5\u652f\u6301\u5206\u5340\uff0c\u9084\u80fd\u5920\u5b58\u5132\u5927\u91cf\u6578\u64da\u3002<\/p>\n<pre><code>-- \u793a\u4f8b\uff1a\u5275\u5efa\u4e00\u500b\u5305\u542b CLOB \u5217\u7684\u5206\u5340\u8868\nCREATE TABLE your_partitioned_table (\n    id NUMBER,\n    data CLOB\n)\nPARTITION BY RANGE (id) (\n    PARTITION p1 VALUES LESS THAN (100),\n    PARTITION p2 VALUES LESS THAN (200)\n);\n<\/code><\/pre>\n<h3 id=\"3-%e6%b8%ac%e8%a9%a6%e5%92%8c%e9%a9%97%e8%ad%89-kWxKjOedIV\">3. \u6e2c\u8a66\u548c\u9a57\u8b49<\/h3>\n<p>\u5728\u9032\u884c\u6578\u64da\u985e\u578b\u7684\u66f4\u6539\u5f8c\uff0c\u52d9\u5fc5\u9032\u884c\u6e2c\u8a66\u4ee5\u78ba\u4fdd\u61c9\u7528\u7a0b\u5e8f\u7684\u529f\u80fd\u4e0d\u53d7\u5f71\u97ff\u3002\u6aa2\u67e5\u6240\u6709\u76f8\u95dc\u7684\u67e5\u8a62\u548c\u64cd\u4f5c\uff0c\u78ba\u4fdd\u5b83\u5011\u80fd\u5920\u6b63\u5e38\u904b\u884c\u3002<\/p>\n<h2 id=\"%e7%b5%90%e8%ab%96-kWxKjOedIV\">\u7d50\u8ad6<\/h2>\n<p>ORA-14031 \u932f\u8aa4\u662f Oracle \u6578\u64da\u5eab\u4e2d\u5e38\u898b\u7684\u554f\u984c\u4e4b\u4e00\uff0c\u4e3b\u8981\u7531\u65bc\u4e0d\u7576\u4f7f\u7528 LONG \u6216 LONG RAW \u985e\u578b\u7684\u5217\u65bc\u5206\u5340\u8868\u4e2d\u6240\u5f15\u8d77\u3002\u901a\u904e\u6aa2\u67e5\u6578\u64da\u985e\u578b\u3001\u4f7f\u7528 CLOB \u6216 BLOB \u4f86\u66ff\u4ee3\u4e0d\u652f\u6301\u7684\u985e\u578b\uff0c\u4e26\u9032\u884c\u5145\u5206\u7684\u6e2c\u8a66\uff0c\u958b\u767c\u8005\u53ef\u4ee5\u6709\u6548\u5730\u89e3\u6c7a\u9019\u4e00\u554f\u984c\u3002<\/p>\n<p>\u5982\u679c\u60a8\u5728\u4f7f\u7528 Oracle \u6578\u64da\u5eab\u6642\u9700\u8981\u66f4\u591a\u7684\u652f\u6301\u6216\u5c0b\u627e\u5408\u9069\u7684 <a href=\"https:\/\/server.hk\">\u9999\u6e2f VPS<\/a> \u89e3\u6c7a\u65b9\u6848\uff0c\u8acb\u96a8\u6642\u8a2a\u554f\u6211\u5011\u7684\u7db2\u7ad9\u4ee5\u7372\u53d6\u66f4\u591a\u4fe1\u606f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u89e3\u6c7a ORA-14031 \u932f\u8aa4\uff1a\u5206\u5340\u5217\u4e0d\u80fd\u4f7f\u7528 LONG \u6216 LONG RAW \u985e\u578b\uff0c\u63d0\u4f9b\u6545\u969c\u4fee\u5fa9\u548c\u9060\u7a0b\u8655\u7406\u65b9\u6848\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-129363","post","type-post","status-publish","format-standard","hentry","category-database"],"_links":{"self":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/129363","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=129363"}],"version-history":[{"count":1,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/129363\/revisions"}],"predecessor-version":[{"id":129364,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/129363\/revisions\/129364"}],"wp:attachment":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/media?parent=129363"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/categories?post=129363"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/tags?post=129363"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}