{"id":101307,"date":"2026-09-06T15:57:11","date_gmt":"2026-09-06T07:57:11","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/101307.html"},"modified":"2026-09-06T15:57:11","modified_gmt":"2026-09-06T07:57:11","slug":"%e3%80%90oracle%e4%b8%93%e6%a0%8f%e3%80%91%e4%ba%94%e7%b1%bb%e7%ba%a6%e6%9d%9f%e5%91%bd%e5%90%8d-%e5%ae%9e%e8%b7%b5%e5%bb%ba%e8%ae%ae","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/101307.html","title":{"rendered":"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae"},"content":{"rendered":"<p>Oracle &amp;&amp; OceanBase \u76f8\u5173\u6587\u6863&#xff0c;\u5e0c\u671b\u4e92\u76f8\u5b66\u4e60&#xff0c;<img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"45\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd61dece.png\" width=\"45\" \/>\u5171\u540c\u8fdb\u6b65<\/p>\n<p>\u98ce123456789&#xff5e;-CSDN\u535a\u5ba2<\/p>\n<hr \/>\n<h2>1.\u80cc\u666f<\/h2>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u6700\u8fd1\u5bf9\u6bd4\u4e24\u4e2a\u4e0d\u540c\u73af\u5883\u7684\u5e93\u65f6&#xff0c;\u53d1\u73b0\u591a\u51fa\u6765\u5f88\u591a<span style=\"background-color:#f9eda6\">SYS_C00107980<\/span> \u7684\u7ea6\u675f\u3002\u5c24\u5176\u662f\u751f\u4ea7\u6570\u636e\u5e93&#xff0c;\u547d\u540d\u6ca1\u6709\u6309\u7167\u89c4\u8303\u7ea6\u5b9a\u8d70\u3002<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u672c\u6587\u4e3b\u8981\u9488\u5bf9 <span style=\"background-color:#ffd7b9\">oracle\u00a0 \u7ea6\u675f\u7684\u521b\u5efa\u3001\u547d\u540d\u3001\u9ed8\u8ba4\u540d\u79f0\u4fee\u6539&#xff0c;\u5229\u5f0a\u5206\u6790 \u53ca\u76f8\u5173\u77e5\u8bc6\u70b9\u6574\u7406<\/span>\u3002<\/p>\n<h2 style=\"background-color:transparent\">2.\u5b9e\u9a8c- \u521b\u5efa\u53ca\u4fee\u6539<\/h2>\n<h3 style=\"background-color:transparent\">2.1 \u6574\u4f53\u8bf4\u660e<\/h3>\n<p>\u00a0 \u00a0 \u00a0 Oracle\u7ea6\u675f\u662f\u6570\u636e\u5e93\u5c42\u9762\u4fdd\u969c\u6570\u636e\u5b8c\u6574\u6027\u7684\u6838\u5fc3\u673a\u5236&#xff0c;\u672c\u8d28\u662f<span style=\"background-color:#f9eda6\">\u4f9d\u9644\u4e8e\u8868\u7684\u5143\u6570\u636e\u58f0\u660e<\/span>&#xff0c;\u90e8\u5206\u7ea6\u675f\u4f1a\u81ea\u52a8\u5173\u8054\u7269\u7406\u7d22\u5f15&#xff0c;\u6240\u6709\u7ea6\u675f\u89c4\u5219\u5728<span style=\"color:#fe2c24\">DML\u6267\u884c\u77ac\u95f4\u7531\u6570\u636e\u5e93\u5185\u6838\u5f3a\u5236\u62e6\u622a<\/span>&#xff0c;\u6bd4\u5e94\u7528\u5c42\u6821\u9a8c\u66f4\u96be\u7ed5\u8fc7\u3001\u66f4\u53ef\u9760\u3002<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u4e94\u5927\u6838\u5fc3\u7ea6\u675f\u7c7b\u578b&#xff1a; \u00a0\u200c\u00a0 \u00a0 1&#xff09;<span style=\"background-color:#98c091\">\u4e3b\u952e\u7ea6\u675f&#xff08;P&#xff09;\u200c<\/span>&#xff1a;\u975e\u7a7a&#043;\u552f\u4e00\u53cc\u91cd\u4fdd\u969c&#xff0c;<span style=\"background-color:#f9eda6\">\u81ea\u52a8\u521b\u5efa\u552f\u4e00\u7d22\u5f15<\/span>&#xff0c;\u7528\u4e8e\u552f\u4e00\u6807\u8bc6\u8868\u4e2d\u6bcf\u4e00\u884c\u6570\u636e&#xff0c;\u4e0d\u5141\u8bb8\u51fa\u73b0\u7a7a\u503c\u548c\u91cd\u590d\u503c\u3002 \u00a0 \u00a0 \u00a02&#xff09;\u200c<span style=\"background-color:#c7e6ea\">\u5916\u952e\u7ea6\u675f&#xff08;R&#xff09;\u200c<\/span>&#xff1a;\u4fdd\u969c\u5173\u8054\u8868\u4e4b\u95f4\u7684\u5f15\u7528\u5b8c\u6574\u6027&#xff0c;\u5b50\u8868\u5b57\u6bb5\u503c\u5fc5\u987b\u5728\u7236\u8868\u5bf9\u5e94\u5b57\u6bb5\u4e2d\u5b58\u5728&#xff0c;\u5916\u952e\u5217\u9ed8\u8ba4\u5141\u8bb8\u4e3a\u7a7a&#xff0c;\u4e0d\u4f1a\u81ea\u52a8\u521b\u5efa\u7d22\u5f15&#xff0c;\u5efa\u8bae\u624b\u52a8\u5efa\u7d22\u5f15\u907f\u514d\u9501\u7b49\u5f85\u3002 \u00a0 \u00a0 3&#xff09;\u200c<span style=\"background-color:#a2e043\">\u552f\u4e00\u7ea6\u675f&#xff08;U&#xff09;\u200c<\/span>&#xff1a;\u4fdd\u969c\u5b57\u6bb5\u503c\u5168\u5c40\u552f\u4e00&#xff0c;<span style=\"background-color:#f9eda6\">\u81ea\u52a8\u521b\u5efa\u552f\u4e00\u7d22\u5f15<\/span>&#xff0c;\u5355\u5217\u552f\u4e00\u7ea6\u675f\u5141\u8bb8\u5b58\u5728\u4efb\u610f\u591a\u4e2aNULL\u503c\u3002 \u00a0 \u00a04&#xff09;\u200c<span style=\"background-color:#f9eda6\">\u975e\u7a7a\u7ea6\u675f&#xff08;C&#xff09;\u200c<\/span>&#xff1a;\u5f3a\u5236\u6307\u5b9a\u5b57\u6bb5\u4e0d\u80fd\u63d2\u5165\u7a7a\u503c&#xff0c;\u4e0d\u4f1a\u81ea\u52a8\u521b\u5efa\u7d22\u5f15&#xff0c;\u5c5e\u4e8eCHECK\u7ea6\u675f\u7684\u7279\u6b8a\u5b50\u7c7b\u3002 \u00a0\u200c\u00a0 5&#xff09;<span style=\"background-color:#98c091\">\u68c0\u67e5\u7ea6\u675f&#xff08;C&#xff09;\u200c<\/span>&#xff1a;\u81ea\u5b9a\u4e49\u6570\u636e\u6821\u9a8c\u89c4\u5219&#xff0c;\u6bd4\u5982\u9650\u5236\u5b57\u6bb5\u53d6\u503c\u8303\u56f4\u3001\u683c\u5f0f\u7b49&#xff0c;\u63d2\u5165\/\u66f4\u65b0\u6570\u636e\u65f6\u89e6\u53d1\u89c4\u5219\u6821\u9a8c\u3002<\/p>\n<p>&#8211;\u521b\u5efa\u8868<br \/>\ncreate table aaa<br \/>\n(kid number,<br \/>\n typ  varchar2(2),<br \/>\n nam varchar2(50),<br \/>\n bankkid varchar2(50)<br \/>\n );<\/p>\n<p> create table bbb<br \/>\n(kid varchar2(50),<br \/>\n banknam varchar2(50),<br \/>\n banktyp varchar2(50)<br \/>\n )<\/p>\n<p>\u00a0 \u00a0 \u4ee5\u4e0b\u4e3b\u8981\u9488\u5bf9 \u4e3b\u952e\u7ea6\u675f\u3001\u5916\u952e\u7ea6\u675f\u3001\u552f\u4e00\u7ea6\u675f&#xff0c;\u4ee5\u53ca\u975e\u7a7a\u7ea6\u675f\u3001\u68c0\u67e5\u7ea6\u675f \u8fdb\u884c\u5b9e\u9a8c\u589e\u3001\u6539\u3002<\/p>\n<p>\u4f4d\u7f6e&#xff1a;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"125\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd62faa8.png\" width=\"518\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"170\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd63b7f1.png\" width=\"578\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"102\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd6493a1.png\" width=\"565\" \/><\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0\u5176\u4e2d\u4e3b\u952e\u7d22\u5f15\u53ef\u4ee5\u4e0d\u8f93\u5165\u540d\u79f0&#xff0c;\u4f7f\u7528\u7cfb\u7edf\u751f\u6210\u7684\u9ed8\u8ba4\u540d\u79f0&#xff08;\u5982\u00a0SYS_C0012345&#xff09;\u3002\u5176\u4ed6\u5fc5\u987b\u6709\u540d\u79f0\u624d\u53ef\u4ee5\u4fdd\u5b58\u3002<\/p>\n<h3 style=\"background-color:transparent\">2.2 \u4e3b\u952e\u7ea6\u675f P\u00a0<\/h3>\n<p>Keys: Primary\u00a0 \u00a0 \u00a0&#xff08;\u4e3b\u952e\u7ea6\u675f\u53ef\u4ee5\u5728\u521b\u5efa\u8868 \u6216\u4e4b\u540e\u589e\u52a0&#xff0c;\u8bed\u6cd5\u4e00\u6837&#xff09;<\/p>\n<h4>1&#xff09;\u589e\u52a0<\/h4>\n<p>&#8211;\u4e0d\u5e26\u540d\u79f0\u6dfb\u52a0 \u4e3b\u952e<br \/>\nalter table aaa add primary key(kid); <\/p>\n<h4>2&#xff09;\u67e5\u8be2\u7ea6\u675f<\/h4>\n<p>&#8211;\u67e5\u770b\u521b\u5efa\u7684\u4e3b\u952e\u540d\u79f0<br \/>\nSELECT A.constraint_name,   &#8212; \u4e3b\u952e\u7ea6\u675f\u540d<br \/>\n       A.status,            &#8212; \u72b6\u6001 (ENABLED\/DISABLED)<br \/>\n       B.column_name,       &#8212; \u5217\u540d<br \/>\n       B.position           &#8212; \u5217\u987a\u5e8f<br \/>\nFROM   user_constraints A<br \/>\nJOIN   user_cons_columns B<br \/>\nON     A.constraint_name &#061; B.constraint_name<br \/>\nWHERE  A.table_name &#061; &#039;AAA&#039;<br \/>\nAND    A.constraint_type &#061; &#039;P&#039;;<\/p>\n<p>\u622a\u56fe&#xff1a; \u521b\u5efa\u540e\u9ed8\u8ba4\u7cfb\u7edf\u751f\u6210\u7684\u9ed8\u8ba4\u540d\u79f0<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"259\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd654f8f.png\" width=\"461\" \/><\/p>\n<p><span style=\"background-color:#f9eda6\">\u6b64\u65f6&#xff0c;\u4f1a\u81ea\u52a8\u751f\u6210\u4e00\u4e2a\u540c\u540d\u7684\u552f\u4e00\u7d22\u5f15<\/span>\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"155\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd66521c.png\" width=\"819\" \/><\/p>\n<p>\u540c\u540d\u7684\u552f\u4e00\u7d22\u5f15\u4e0d\u80fd\u5355\u72ec\u5220\u9664&#xff0c;\u540cpk\u540c\u751f\u547d\u5468\u671f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"161\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd678fed.png\" width=\"1074\" \/><\/p>\n<h4>3&#xff09;\u4fee\u6539<\/h4>\n<p><span style=\"background-color:#a2e043\">\u4fee\u6539\u7ea6\u675f\u540d\u79f0\u00a0 \u6216\u8005\u91cd\u5efa\u4e3b\u952e&#xff1a;<\/span><\/p>\n<p>&#8211;\u4fee\u6539\u7ea6\u675f\u540d\u79f0,\u540c\u65f6\u7d22\u5f15\u7684\u4e5f\u8981\u4fee\u6539       \u5982\u679c\u4e0d\u4fee\u6539\u7d22\u5f15\u7684&#xff0c;\u5220\u9664\u4e3b\u952e\u65f6\u4e5f\u4f1a\u5220\u9664\u7d22\u5f15\u7684<br \/>\nalter index SYS_C00146357 rename to pk_aaa;<\/p>\n<p>alter table AAA<br \/>\n rename constraint SYS_C00146357 to pk_aaa;<br \/>\n&#8211;\u5220\u9664\u4e3b\u952e\u7ea6\u675f<br \/>\nalter table AAA<br \/>\n\u00a0 drop constraint SYS_C00146357 cascade;<\/p>\n<p>&#8211;\u6dfb\u52a0\u5f85\u540d\u79f0\u7684\u4e3b\u952e\u7ea6\u675f<br \/>\nalter table AAA<br \/>\n  add constraint PK_AAA primary key (KID) <\/p>\n<h3 style=\"background-color:transparent\">2.3 \u552f\u4e00\u7ea6\u675f U<\/h3>\n<p>Keys: Unique<\/p>\n<h4>1&#xff09;\u589e\u52a0<\/h4>\n<p>\u00a0 \u00a0 \u00a0 <span style=\"background-color:#ffd7b9\">\u589e\u52a0\u552f\u4e00\u7ea6\u675f\u65f6&#xff0c;\u4f1a\u81ea\u52a8\u589e\u52a0\u4e00\u4e2a\u552f\u4e00\u7d22\u5f15&#xff08;\u540c\u4e3b\u952e\u7ea6\u675f&#xff0c;\u53ea\u6709\u5b83\u4fe9&#xff09;<\/span>\u3002\u9664\u6b64\u5916&#xff0c;\u53ef\u4ee5\u518d\u589e\u52a0\u5176\u4ed6\u7684\u552f\u4e00\u7ea6\u675f; \u4e5f\u53ef\u4ee5\u591a\u5217\u552f\u4e00\u7ea6\u675f\u3002<\/p>\n<p>&#8211;\u589e\u52a0\u552f\u4e00\u7ea6\u675f<br \/>\nalter table AAA<br \/>\n  add constraint UK_AAA unique (TYP); <\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"222\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd693dd1.png\" width=\"802\" \/><\/p>\n<p>\u6ce8\u610f&#xff1a;<span style=\"background-color:#fbd4d0\">\u589e\u52a0\u552f\u4e00\u7ea6\u675f\u65f6&#xff0c;\u4e0d\u53ef\u4ee5\u4e0d\u586b\u5199\u7ea6\u675f\u540d\u79f0&#xff0c;\u5426\u5219\u4f1a\u62a5\u9519<\/span> &#xff08;\u4e0d\u540c\u4e8e\u4e3b\u952e\u7ea6\u675f&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"187\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd6ab9cc.png\" width=\"317\" \/><\/p>\n<h4>2&#xff09;\u4fee\u6539<\/h4>\n<p>\u4fee\u6539\u7ea6\u675f\u540d\u79f0&#xff1a;\u00a0 \u00a0\u540c\u4e3b\u952e<\/p>\n<p>&#8211;\u4fee\u6539\u7ea6\u675f\u540d\u79f0   \u540c\u4e3b\u952e\u7ea6\u675f\u8bed\u6cd5<br \/>\nalter index A1 rename to uk_aaa;<\/p>\n<p>alter table AAA<br \/>\n rename constraint A1 to uk_aaa;<\/p>\n<h4>3&#xff09;\u5220\u9664<\/h4>\n<p>\u5220\u9664\u7ea6\u675f\u540d\u79f0&#xff1a;\u00a0 \u540c\u4e3b\u952e<\/p>\n<p>alter table AAA<br \/>\n  drop constraint UK_AAA cascade;<\/p>\n<h3>2.4 \u5916\u952e\u7ea6\u675f F<\/h3>\n<p>Keys: Foreign<\/p>\n<h4>1&#xff09;\u6dfb\u52a0<\/h4>\n<p>&#8211;\u589e\u52a0\u5916\u952e\u7ea6\u675f<br \/>\nalter table AAA<br \/>\n  add constraint fk_aaa foreign key (BANKKID)<br \/>\n  references bbb (KID); <\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u4ee5\u4e0a\u4f1a\u62a5\u9519&#xff0c;\u56e0\u4e3abbb\u8868\u6ca1\u6709\u552f\u4e00\u7ea6\u675f&#xff0c;\u589e\u52a0\u5982\u4e0b\u3002<\/p>\n<p>alter table BBB<br \/>\n  add constraint PK_BBB primary key (KID) <\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0\u518d\u6b21\u6267\u884c\u5916\u952e\u7ea6\u675f\u589e\u52a0\u8bed\u53e5&#xff0c;ok:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"113\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd6bad8d.png\" width=\"841\" \/><\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0\u5728 Oracle \u6570\u636e\u5e93\u4e2d&#xff0c;\u5916\u952e&#xff08;Foreign Key&#xff09;\u5f15\u7528\u7684\u76ee\u6807\u5217\u200c\u4e0d\u5fc5\u5fc5\u987b\u662f\u4e3b\u952e&#xff08;Primary Key&#xff09;\u200c&#xff0c;\u4f46\u5b83\u200c\u5fc5\u987b\u5177\u6709\u552f\u4e00\u6027\u7ea6\u675f\u200c\u3002<\/p>\n<p>\u5916\u952e\u53ef\u4ee5\u5f15\u7528\u53e6\u4e00\u4e2a\u8868\u7684\u4ee5\u4e0b\u4e24\u79cd\u7ea6\u675f\u4e4b\u4e00&#xff1a;<\/p>\n<li>\u200c\u4e3b\u952e\u7ea6\u675f&#xff08;PRIMARY KEY&#xff09;\u200c&#xff1a;\u6700\u5e38\u89c1&#xff0c;\u4e3b\u952e\u5929\u7136\u5177\u5907<span style=\"background-color:#a2e043\">\u201c\u552f\u4e00\u201d\u4e14\u201c\u975e\u7a7a\u201d<\/span>\u7684\u7279\u6027\u3002<\/li>\n<li>\u200c\u552f\u4e00\u7ea6\u675f&#xff08;UNIQUE&#xff09;\u200c&#xff1a;\u82e5\u76ee\u6807\u5217\u5b9a\u4e49<span style=\"background-color:#a2e043\">\u00a0<\/span><span style=\"background-color:#a2e043\">UNIQUE<\/span><span style=\"background-color:#a2e043\">\u00a0\u7ea6\u675f<\/span>&#xff0c;\u4e5f\u53ef\u4ee5\u88ab\u5176\u4ed6\u8868\u4f5c\u4e3a\u5916\u952e\u5f15\u7528\u3002<\/li>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u5916\u952e\u7684\u4f5c\u7528\u662f<span style=\"background-color:#f9eda6\">\u7ef4\u62a4\u200c\u53c2\u7167\u5b8c\u6574\u6027\u200c&#xff08;Referential\u00a0Integrity&#xff09;<\/span>&#xff0c;\u5373\u5b50\u8868\u4e2d\u7684\u6bcf\u4e00\u884c\u6570\u636e\u5fc5\u987b\u5728\u7236\u8868\u4e2d\u627e\u5230\u200c\u552f\u4e00\u786e\u5b9a\u200c\u7684\u5bf9\u5e94\u8bb0\u5f55\u3002 \u00a0 \u00a0 \u00a0 \u5982\u679c\u7236\u8868\u7684\u5217\u5141\u8bb8\u91cd\u590d\u503c&#xff0c;\u5b50\u8868\u7684\u4e00\u6761\u8bb0\u5f55\u5c31\u65e0\u6cd5\u660e\u786e\u6307\u5411\u7236\u8868\u7684\u54ea\u4e00\u6761\u5177\u4f53\u8bb0\u5f55&#xff0c;\u4ece\u800c\u7834\u574f\u6570\u636e\u4e00\u81f4\u6027\u903b\u8f91\u3002\u56e0\u6b64&#xff0c;Oracle\u00a0\u5f3a\u5236\u8981\u6c42\u5916\u952e\u5f15\u7528\u7684\u5217\u5fc5\u987b\u62e5\u6709\u00a0\u200cPRIMARY\u00a0KEY\u200c\u00a0\u6216\u00a0\u200cUNIQUE\u200c\u00a0\u7ea6\u675f\u3002<\/p>\n<p>\u00a0 \u00a0 \u00a0\u4e5f\u53ef\u4ee5\u5728\u521b\u5efa\u8868\u65f6&#xff0c;\u7528\u5217\u7ea7\u6216\u8868\u7ea7\u7ea6\u675f\u521b\u5efa\u5916\u952e\u7d22\u5f15&#xff1a;<\/p>\n<p>&#8211;\u5217\u7ea7\u7ea6\u675f&#xff08;Column Level&#xff09;<br \/>\n CREATE TABLE ccc (<br \/>\n     kid number primary key,<br \/>\n     typ  varchar2(2),<br \/>\n     nam varchar2(50),<br \/>\n     bankkid varchar2(50) CONSTRAINT fk_ccc REFERENCES bbb(kid)<br \/>\n);<\/p>\n<p>&#8211;\u8868\u7ea7\u7ea6\u675f&#xff08;Table Level&#xff09;<br \/>\nCREATE TABLE ddd (<br \/>\n     kid number primary key,<br \/>\n     typ  varchar2(2),<br \/>\n     nam varchar2(50),<br \/>\n     bankkid varchar2(50),<br \/>\n    CONSTRAINT fk_ddd FOREIGN KEY (bankkid)  REFERENCES bbb(kid)<br \/>\n); <\/p>\n<h4>2&#xff09;\u4fee\u6539\u3001\u5220\u9664<\/h4>\n<p>\u4fee\u6539\u5916\u952e\u7d22\u5f15\u3001\u5220\u9664\u5916\u952e\u7d22\u5f15&#xff08;\u540c\u5176\u4ed6&#xff09;<\/p>\n<p>&#8211;\u91cd\u547d\u540d &#xff08;\u540c\u5176\u4ed6&#xff09;<br \/>\nalter table DDD<br \/>\n rename constraint FK_DDD to FK_DDD1;<\/p>\n<p>&#8211;\u5220\u9664 &#xff08;\u540c\u5176\u4ed6&#xff09;<br \/>\nalter table DDD<br \/>\n  drop constraint FK_DDD;<\/p>\n<h3 style=\"background-color:transparent\">2.5 \u975e\u7a7a\u7ea6\u675f C<\/h3>\n<p>Columns &#xff1a;\u5217\u4e0a\u76f4\u63a5\u589e\u52a0\u8be5\u5c5e\u6027\u5373\u53ef<\/p>\n<h4>1&#xff09;\u5b9a\u4e49<\/h4>\n<ul>\n<li>\u200c\u975e\u7a7a\u7ea6\u675f (NOT NULL Constraint)\u200c&#xff1a;\n<ul>\n<li>\u200c\u6027\u8d28\u200c&#xff1a;\u903b\u8f91\u89c4\u5219\u3002<\/li>\n<li>\u200c\u4f5c\u7528\u200c&#xff1a;\u5f3a\u5236\u5217\u4e2d\u4e0d\u80fd\u5305\u542b\u00a0NULL\u00a0\u503c\u3002<\/li>\n<li>\u200c\u5b9e\u73b0\u200c&#xff1a;Oracle \u5728\u6570\u636e\u5b57\u5178\u4e2d\u8bb0\u5f55\u8be5\u5217\u5c5e\u6027\u6765\u5b9e\u65bd&#xff0c;\u200c\u9ed8\u8ba4\u60c5\u51b5\u4e0b\u4e0d\u4f1a\u81ea\u52a8\u521b\u5efa\u7d22\u5f15\u200c\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h4>2&#xff09;\u6dfb\u52a0<\/h4>\n<p>&#8211;\u521b\u5efa\u65f6\u6307\u5b9a<br \/>\nCREATE TABLE eee (<br \/>\n     kid number,<br \/>\n     typ  varchar2(2),<br \/>\n     nam varchar2(50),<br \/>\n     bankkid varchar2(50) not null<br \/>\n);<br \/>\n&#8211;\u4fee\u6539\u4e3a\u975e\u7a7a\u7ea6\u675f<br \/>\nALTER TABLE aaa MODIFY typ varchar2(10) NOT NULL;<\/p>\n<p>ALTER TABLE aaa MODIFY nam  NOT NULL; <\/p>\n<h4 style=\"background-color:transparent\">3&#xff09;\u4fee\u6539<\/h4>\n<p>\u4fee\u6539\u975e\u7a7a \u4e3a\u53ef\u7a7a\u65f6&#xff1a;<\/p>\n<p>alter table EEE modify bankkid null;<\/p>\n<h3 style=\"background-color:transparent\">2.6 \u68c0\u67e5\u7ea6\u675f\u00a0C<\/h3>\n<p>Checks: \u589e\u52a0\u76f8\u5173\u7684\u6761\u4ef6<\/p>\n<h4>1&#xff09;\u5b9a\u4e49<\/h4>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u68c0\u67e5\u7ea6\u675f&#xff08;CHECK Constraint&#xff09;\u200c \u662f Oracle \u6570\u636e\u5e93\u4e2d\u7528\u4e8e\u4fdd\u8bc1\u6570\u636e\u5b8c\u6574\u6027\u548c\u51c6\u786e\u6027\u7684\u5173\u952e\u673a\u5236\u3002\u5b83\u901a\u8fc7\u5b9a\u4e49\u4e00\u4e2a\u903b\u8f91\u8868\u8fbe\u5f0f&#xff08;\u5e03\u5c14\u6761\u4ef6&#xff09;&#xff0c;\u5f3a\u5236\u8868\u4e2d\u6bcf\u4e00\u884c\u6570\u636e\u5728\u63d2\u5165\u6216\u66f4\u65b0\u65f6\u5fc5\u987b\u6ee1\u8db3\u8be5\u6761\u4ef6\u3002\u5982\u679c\u64cd\u4f5c\u5bfc\u81f4\u8868\u8fbe\u5f0f\u7ed3\u679c\u4e3a\u00a0FALSE&#xff0c;\u6570\u636e\u5e93\u5c06\u62d2\u7edd\u6267\u884c\u5e76\u62a5\u9519&#xff1b;\u5982\u679c\u7ed3\u679c\u4e3a\u00a0TRUE\u00a0\u6216\u00a0UNKNOWN&#xff08;\u901a\u5e38\u6d89\u53ca NULL \u503c&#xff09;&#xff0c;\u5219\u64cd\u4f5c\u5141\u8bb8\u901a\u8fc7\u3002<\/p>\n<p>\u200c\u00a0 \u00a0 \u00a0<span style=\"background-color:#ffd7b9\"> \u57df\u5b8c\u6574\u6027\u9a8c\u8bc1\u200c<\/span>&#xff1a;\u9650\u5236\u5217\u503c\u7684\u8303\u56f4\u3001\u683c\u5f0f\u6216\u7279\u5b9a\u96c6\u5408\u3002\u4f8b\u5982&#xff1a;\u5e74\u9f84\u5fc5\u987b\u5927\u4e8e\u00a00&#xff0c;\u6027\u522b\u53ea\u80fd\u662f\u00a0&#039;M&#039;\u00a0\u6216\u00a0&#039;F&#039;\u3002 \u00a0\u200c\u00a0 \u00a0 \u00a0<span style=\"background-color:#f9eda6\">\u4e1a\u52a1\u89c4\u5219\u843d\u5730\u200c<\/span>&#xff1a;\u5c06\u4e1a\u52a1\u903b\u8f91\u76f4\u63a5\u56fa\u5316\u5728\u6570\u636e\u5e93\u5c42&#xff0c;\u9632\u6b62\u56e0\u5e94\u7528\u5c42\u6f0f\u6d1e\u6216\u76f4\u8fde\u6570\u636e\u5e93\u64cd\u4f5c\u5bfc\u81f4\u7684\u201c\u810f\u6570\u636e\u201d\u3002 \u00a0\u200c\u00a0 \u00a0 <span style=\"background-color:#d4e9d5\">\u591a\u5217\u5173\u8054\u6821\u9a8c\u200c<\/span>&#xff1a;\u53ef\u4ee5\u6bd4\u8f83\u540c\u4e00\u884c\u4e2d\u4e0d\u540c\u5217\u7684\u503c\u3002\u4f8b\u5982&#xff1a;\u7ed3\u675f\u65e5\u671f\u5fc5\u987b\u665a\u4e8e\u5f00\u59cb\u65e5\u671f\u00a0(end_date\u00a0&gt;\u00a0start_date)<\/p>\n<h4>2&#xff09;\u521b\u5efa<\/h4>\n<p>CHECK \u7ea6\u675f\u53ef\u4ee5\u5728\u521b\u5efa\u8868\u65f6\u5b9a\u4e49&#xff08;\u5217\u7ea7\u6216\u8868\u7ea7&#xff09;&#xff0c;\u4e5f\u53ef\u4ee5\u5728\u8868\u521b\u5efa\u540e\u901a\u8fc7\u00a0ALTER TABLE\u00a0\u6dfb\u52a0\u3002<\/p>\n<p>&#8211;\u5217\u7ea7<br \/>\nCREATE TABLE fff (<br \/>\n    emp_id NUMBER PRIMARY KEY,<br \/>\n    salary NUMBER(10, 2) CONSTRAINT chk_sal_positive CHECK (salary &gt; 0),<br \/>\n    gender CHAR(1) CONSTRAINT chk_gender_valid CHECK (gender IN (&#039;M&#039;, &#039;F&#039;))<br \/>\n);<br \/>\n&#8211;\u8868\u7ea7<br \/>\nCREATE TABLE ggg (<br \/>\n    proj_id NUMBER PRIMARY KEY,<br \/>\n    start_date DATE,<br \/>\n    end_date DATE,<br \/>\n    CONSTRAINT chk_date_order CHECK (end_date &gt;&#061; start_date)<br \/>\n);<\/p>\n<p>&#8211;\u5982\u679c\u8868\u5df2\u5b58\u5728\u4e14\u6570\u636e\u7b26\u5408\u65b0\u89c4\u5219&#xff0c;\u4fee\u6539\u6dfb\u52a0<br \/>\nALTER TABLE fff<br \/>\nADD CONSTRAINT chk_salary_range<br \/>\nCHECK (salary &gt;&#061; 200 AND salary &lt;&#061; 100000); <\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"114\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd6cbd06.png\" width=\"613\" \/><\/p>\n<h4>3&#xff09;\u6ce8\u610f<\/h4>\n<p>\u6ce8\u610f&#xff1a;<\/p>\n<li>\u200cDML \u6027\u80fd\u5f71\u54cd\u200c&#xff1a;\u6bcf\u6b21\u00a0INSERT\u00a0\u6216\u00a0UPDATE\u00a0\u90fd\u4f1a\u89e6\u53d1\u7ea6\u675f\u68c0\u67e5\u3002\u5bf9\u4e8e\u9ad8\u9891\u5199\u5165\u7684\u5927\u8868&#xff0c;\u590d\u6742\u7684 CHECK \u8868\u8fbe\u5f0f&#xff08;\u5982\u5305\u542b\u51fd\u6570\u8c03\u7528\u3001\u6b63\u5219\u8868\u8fbe\u5f0f\u00a0REGEXP_LIKE&#xff09;\u53ef\u80fd\u6210\u4e3a\u6027\u80fd\u74f6\u9888\u3002<\/li>\n<li>\u200cDELETE \u4e0d\u89e6\u53d1\u200c&#xff1a;\u6267\u884c\u00a0DELETE\u00a0\u8bed\u53e5\u65f6&#xff0c;Oracle \u200c\u4e0d\u4f1a\u200c\u9a8c\u8bc1 CHECK \u7ea6\u675f&#xff0c;\u56e0\u4e3a\u5220\u9664\u6570\u636e\u4e0d\u4f1a\u5bfc\u81f4\u5269\u4f59\u6570\u636e\u8fdd\u53cd\u884c\u7ea7\u6761\u4ef6<\/li>\n<h3 style=\"background-color:transparent\">2.7.\u5173\u952e\u4e8b\u5b9e\u8865\u5145<\/h3>\n<p>\u00a0 \u00a0 \u00a0 1&#xff09;\u4e3b\u952e\u7ea6\u675f\u200c\u5fc5\u987b\u200c\u6709\u552f\u4e00\u7d22\u5f15\u652f\u6491&#xff1b;\u82e5\u672a\u6307\u5b9a\u7d22\u5f15\u540d&#xff0c;Oracle\u00a0\u4f1a\u200c\u81ea\u52a8\u521b\u5efa\u540c\u540d\u7d22\u5f15\u200c&#xff08;\u7ea6\u675f\u540d\u00a0&#061;\u00a0\u7d22\u5f15\u540d&#xff09;\u3002 \u00a0 \u00a0 \u00a0 2&#xff09;\u5220\u9664\u4e3b\u952e\u7ea6\u675f\u65f6&#xff0c;\u5176\u5173\u8054\u7d22\u5f15\u540c\u6b65\u5220\u9664&#xff1b;\u82e5\u7d22\u5f15\u662f\u624b\u52a8\u521b\u5efa\u4e14\u540d\u79f0\u4e0d\u540c&#xff0c;\u5219\u9700\u5355\u72ec\u5904\u7406\u3002 \u00a0 \u00a0 \u00a0 3&#xff09;\u9ed8\u8ba4\u540d\u79f0\u957f\u5ea6\u53d7\u9650\u4e8e\u00a0Oracle\u00a0\u5bf9\u8c61\u540d\u4e0a\u9650&#xff08;30\u00a0\u5b57\u7b26&#xff0c;12c&#043;\u00a0\u53ef\u66f4\u957f&#xff09;&#xff0c;\u4f46\u00a0SYS_Cxxxxx\u00a0\u683c\u5f0f\u672c\u8eab\u65e0\u4e1a\u52a1\u542b\u4e49\u3002<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0\u5728 Oracle \u4e2d\u6267\u884c DROP TABLE \u65f6&#xff0c;\u200c\u8be5\u8868\u4e0a\u6240\u6709\u4f9d\u8d56\u5bf9\u8c61&#xff08;\u5305\u62ec\u7d22\u5f15\u3001\u7ea6\u675f\u3001\u89e6\u53d1\u5668&#xff09;\u5747<span style=\"background-color:#f9eda6\">\u4f1a\u88ab\u81ea\u52a8\u79fb\u9664\u200c&#xff0c;\u65e0\u9700\u989d\u5916\u6307\u5b9a<\/span>\u3002<\/p>\n<ul>\n<li>\u7d22\u5f15\u200c&#xff1a;\u6240\u6709\u57fa\u4e8e\u8be5\u8868\u7684\u7d22\u5f15&#xff08;\u542b\u4e3b\u952e\/\u552f\u4e00\u7ea6\u675f\u81ea\u52a8\u521b\u5efa\u7684\u7d22\u5f15&#xff09;\u968f\u8868\u4e00\u540c\u5220\u9664\u3002<\/li>\n<li>\u200c\u7ea6\u675f\u200c&#xff1a;\u8be5\u8868\u81ea\u8eab\u5b9a\u4e49\u7684\u6240\u6709\u7ea6\u675f&#xff08;\u4e3b\u952e\u3001\u5916\u952e\u3001\u552f\u4e00\u3001\u68c0\u67e5\u7b49&#xff09;\u4e00\u5e76\u5220\u9664&#xff1b;\u82e5\u5176\u4ed6\u8868\u5b58\u5728\u200c\u5916\u952e\u5f15\u7528\u6b64\u8868\u200c&#xff0c;\u9ed8\u8ba4\u4f1a\u62a5\u9519\u963b\u6b62\u5220\u9664&#xff0c;\u9700\u52a0\u00a0CASCADE CONSTRAINTS\u00a0\u9009\u9879\u5f3a\u5236\u7ea7\u8054\u5220\u9664\u5f15\u7528\u7ea6\u675f\u3002<\/li>\n<li>\u200c\u5176\u4ed6\u5bf9\u8c61\u200c&#xff1a;\n<ul>\n<li>\u89c6\u56fe\u3001\u540c\u4e49\u8bcd&#xff1a;\u5b9a\u4e49\u4fdd\u7559\u4f46\u72b6\u6001\u53d8\u4e3a\u00a0INVALID&#xff08;\u5931\u6548&#xff09;&#xff0c;\u9700\u624b\u52a8\u91cd\u5efa\u6216\u91cd\u65b0\u7f16\u8bd1\u3002<\/li>\n<li>\u89e6\u53d1\u5668&#xff1a;\u968f\u8868\u5220\u9664&#xff08;\u975e\u201c\u4e0d\u89e6\u53d1\u201d&#xff0c;\u800c\u662f\u5bf9\u8c61\u672c\u8eab\u88ab\u6e05\u9664&#xff09;\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u200c\u56de\u6536\u7ad9\u673a\u5236\u200c&#xff08;Oracle 10g&#043;&#xff09;&#xff1a;\n<ul>\n<li>\u9ed8\u8ba4\u00a0DROP TABLE \u8868\u540d\u00a0\u2192 \u8868\u53ca\u5173\u8054\u5bf9\u8c61\u8fdb\u5165\u56de\u6536\u7ad9&#xff08;\u53ef\u00a0FLASHBACK\u00a0\u6062\u590d&#xff0c;\u6062\u590d\u540e\u7d22\u5f15\/\u7ea6\u675f\u540d\u79f0\u53ef\u80fd\u7531\u7cfb\u7edf\u91cd\u547d\u540d&#xff09;\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>\u4e3b\u952e\u6216\u552f\u4e00\u7ea6\u675f\u81ea\u52a8\u521b\u5efa\u7d22\u5f15&#xff1a; \u00a0 \u00a0 \u00a0 \u5f53\u5b9a\u4e49\u00a0PRIMARY\u00a0KEY\u00a0\u6216\u00a0UNIQUE\u00a0\u7ea6\u675f\u65f6&#xff0c;Oracle\u00a0\u4f1a\u200c\u81ea\u52a8\u521b\u5efa\u4e00\u4e2a\u552f\u4e00\u7d22\u5f15\u200c\u6765\u652f\u6491\u8be5\u7ea6\u675f\u3002 \u00a0 \u00a0 \u00a0 PRIMARY\u00a0KEY\u00a0&#061;\u00a0<span style=\"background-color:#a2e043\">NOT\u00a0NULL\u00a0&#043;\u00a0UNIQUE\u00a0&#043;\u00a0\u200c\u81ea\u52a8\u521b\u5efa\u552f\u4e00\u7d22\u5f15\u200c<\/span>\u3002 \u00a0 \u00a0 \u00a0 UNIQUE\u00a0&#061;\u00a0<span style=\"background-color:#ffd7b9\">UNIQUE\u00a0(\u5141\u8bb8NULL)\u00a0&#043;\u00a0\u200c\u81ea\u52a8\u521b\u5efa\u552f\u4e00\u7d22\u5f15\u200c<\/span>\u3002 \u200c\u00a0 \u00a0 \u00a0 \u6ce8\u610f\u200c&#xff1a;\u5355\u7eaf\u7684\u00a0NOT\u00a0NULL\u00a0\u7ea6\u675f\u200c\u4e0d\u4f1a\u200c\u89e6\u53d1\u81ea\u52a8\u7d22\u5f15\u521b\u5efa\u3002<\/p>\n<h2 style=\"background-color:transparent\">3.\u5229\u5f0a\u603b\u7ed3 |\u5b9e\u8df5\u5efa\u8bae\u00a0<img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"50\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd6d8006.gif\" width=\"50\" \/><\/h2>\n<h3>3.1 \u8bf4\u660e<\/h3>\n<p>\u00a0 \u00a0 \u00a0 Oracle \u5141\u8bb8\u4e3b\u952e\u7ea6\u675f\u53ca\u5173\u8054\u7d22\u5f15\u4f7f\u7528\u7cfb\u7edf\u751f\u6210\u7684\u9ed8\u8ba4\u540d\u79f0&#xff08;\u5982\u00a0SYS_C0012345&#xff09;&#xff0c;\u6280\u672f\u4e0a\u65e0\u529f\u80fd\u969c\u788d&#xff0c;\u4f46\u200c\u5f3a\u70c8\u4e0d\u5efa\u8bae\u5728\u751f\u4ea7\u73af\u5883\u957f\u671f\u91c7\u7528\u200c\u3002<\/p>\n<h3>3.2 \u5229\u5f0a\u5206\u6790<\/h3>\n<table>\n<tr>\u7ef4\u5ea6\u9ed8\u8ba4\u540d\u79f0&#xff08;\u7cfb\u7edf\u751f\u6210&#xff09;\u81ea\u5b9a\u4e49\u89c4\u8303\u540d\u79f0&#xff08;\u63a8\u8350&#xff09;<\/tr>\n<tbody>\n<tr>\n<td>\u200c\u2705 \u4f18\u70b9\u200c<\/td>\n<td style=\"width:315px\">&#8211; \u521b\u5efa\u8bed\u53e5\u7b80\u6d01&#xff0c;\u65e0\u9700\u989d\u5916\u547d\u540d &#8211; \u907f\u514d\u4eba\u4e3a\u547d\u540d\u51b2\u7a81\u6216\u62fc\u5199\u9519\u8bef<\/td>\n<td style=\"width:321px\">&#8211; \u200c\u53ef\u8bfb\u6027\u5f3a\u200c&#xff1a;\u5982\u00a0PK_EMPLOYEE\u00a0\u4e00\u773c\u8bc6\u522b\u8868\u4e0e\u7ea6\u675f\u7c7b\u578b &#8211; \u200c\u8fd0\u7ef4\u9ad8\u6548\u200c&#xff1a;\u62a5\u9519\/\u65e5\u5fd7\u4e2d\u5feb\u901f\u5b9a\u4f4d\u5bf9\u8c61&#xff08;\u907f\u514d\u67e5\u6570\u636e\u5b57\u5178\u53cd\u67e5&#xff09; &#8211; \u200c\u4fbf\u4e8e\u81ea\u52a8\u5316\u811a\u672c\u200c&#xff1a;\u7edf\u4e00\u547d\u540d\u89c4\u5219\u652f\u6301\u6279\u91cf\u7ba1\u7406\u3001\u76d1\u63a7\u3001\u8fc1\u79fb<\/td>\n<\/tr>\n<tr>\n<td>\u200c\u274c \u7f3a\u70b9\u200c<\/td>\n<td style=\"width:315px\">&#8211; \u200c\u4e0d\u53ef\u8bfb\u200c&#xff1a;SYS_C0012345\u00a0\u65e0\u6cd5\u4f53\u73b0\u6240\u5c5e\u8868\u6216\u7528\u9014 &#8211; \u200c\u6392\u67e5\u56f0\u96be\u200c&#xff1a;\u62a5\u9519\u00a0ORA-00001: unique constraint (SYS_C0012345) violated\u00a0\u9700\u989d\u5916\u67e5\u8be2\u00a0USER_CONSTRAINTS\u00a0\u624d\u80fd\u5b9a\u4f4d\u8868 &#8211; \u200c\u534f\u4f5c\u98ce\u9669\u200c&#xff1a;\u65b0\u6210\u5458\/\u8de8\u56e2\u961f\u7ef4\u62a4\u6210\u672c\u9ad8&#xff0c;\u6613\u8bef\u5220\u6216\u91cd\u590d\u5efa\u7ea6\u675f &#8211; \u200c\u5de5\u5177\u517c\u5bb9\u6027\u5dee\u200c&#xff1a;\u90e8\u5206 ER \u5de5\u5177\u3001CI\/CD \u6821\u9a8c\u811a\u672c\u4f9d\u8d56\u8bed\u4e49\u5316\u547d\u540d<\/td>\n<td style=\"width:321px\">&#8211; \u9700\u5236\u5b9a\u5e76\u9075\u5b88\u547d\u540d\u89c4\u8303&#xff08;\u5982\u00a0&lt;TABLE&gt;_PK&#xff09; &#8211; \u521d\u59cb\u5efa\u8868\u8bed\u53e5\u7a0d\u957f<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>3.3.\u5b9e\u8df5\u5efa\u8bae<\/h3>\n<p>\u200c\u00a0 \u00a0 1&#xff09;\u5f00\u53d1\/\u6d4b\u8bd5\u73af\u5883\u200c&#xff1a;\u53ef\u4e34\u65f6\u7528\u9ed8\u8ba4\u540d\u52a0\u901f\u539f\u578b\u9a8c\u8bc1\u3002 \u200c\u00a0 \u00a0 2&#xff09;\u751f\u4ea7\u73af\u5883\u200c&#xff1a;\u200c\u5fc5\u987b\u5f3a\u5236\u81ea\u5b9a\u4e49\u547d\u540d\u200c&#xff0c;\u9075\u5faa\u56e2\u961f\u89c4\u8303&#xff08;<span style=\"background-color:#ffd7b9\">\u4f8b&#xff1a;\u4e3b\u952e\u00a0PK_&lt;TABLE&gt;&#xff0c;\u552f\u4e00\u7d22\u5f15\u00a0UK_&lt;TABLE&gt;_&lt;COLS&gt;&#xff0c;\u666e\u901a\u7d22\u5f15\u00a0IX_&lt;TABLE&gt;_&lt;COLS&gt;<\/span>&#xff09;\u3002 \u00a0 \u00a0 3&#xff09;\u82e5\u5df2\u5b58\u5728\u5927\u91cf\u9ed8\u8ba4\u540d\u5bf9\u8c61&#xff0c;\u5efa\u8bae\u901a\u8fc7\u811a\u672c\u6279\u91cf\u91cd\u547d\u540d&#xff08;\u9700\u505c\u673a\u7a97\u53e3\u00a0&#043;\u00a0\u5145\u5206\u6d4b\u8bd5&#xff09;&#xff0c;\u907f\u514d\u9057\u7559\u6280\u672f\u503a\u3002<\/p>\n<p>\u6ce8&#xff1a;Oracle \u5b98\u65b9\u6587\u6863\u867d\u672a\u7981\u6b62\u9ed8\u8ba4\u540d&#xff0c;\u4f46<span style=\"background-color:#f9eda6\">\u6240\u6709\u4f01\u4e1a\u7ea7\u5f00\u53d1\u89c4\u8303&#xff08;\u5982\u963f\u91cc\u3001\u534e\u4e3a\u3001Oracle \u81ea\u8eab\u6700\u4f73\u5b9e\u8df5&#xff09;\u5747\u660e\u786e\u8981\u6c42\u8bed\u4e49\u5316\u547d\u540d<\/span>&#xff0c;\u4ee5\u63d0\u5347\u53ef\u7ef4\u62a4\u6027\u4e0e\u53ef\u89c2\u6d4b\u6027\u3002<\/p>\n<\/p>\n<h3>\u5230\u8fd9\u91cc\u5427&#xff1a;ok\u00a0<img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"31\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd6e4cb7.gif\" width=\"31\" \/><\/h3>\n<hr \/>\n<p>\u9879\u76ee\u7ba1\u7406&#8211;\u76f8\u5173\u77e5\u8bc6\u00a0\u00a0\u00a0<img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"45\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd61dece.png\" width=\"45\" \/><\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u9879\u76ee\u7ee9\u6548\u57df1\/2-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u9879\u76ee\u7ee9\u6548\u57df1\/2_\u516b\u5927\u7ee9\u6548\u57df\u548c\u5341\u5927\u7ba1\u7406\u6709\u4ec0\u4e48\u8054\u7cfb-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u9879\u76ee\u7ee9\u6548\u57df2\/2_\u7ee9\u6548\u57df \u56e2\u4e0d\u7b56\u5212-CSDN\u535a\u5ba2<\/p>\n<p>\u9ad8\u9879-\u6848\u4f8b\u5206\u6790\u4e07\u80fd\u7b54\u6848&#xff08;\u4f5c\u4e1a\u5206\u4eab&#xff09;-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u8ba1\u7b97\u9898\u516c\u5f0f\u3010\u590d\u4e60\u3011_\u9879\u76ee\u7ba1\u7406\u8fdb\u5ea6\u8ba1\u7b97\u9898\u516c\u5f0f:\u4e50\u89c2-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u914d\u7f6e\u7ba1\u7406\u4e0e\u53d8\u66f4-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u9879\u76ee\u7ba1\u7406\u79d1\u5b66\u57fa\u7840-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u9ad8\u7ea7\u9879\u76ee\u7ba1\u7406-CSDN\u535a\u5ba2<\/p>\n<p>\u9879\u76ee\u7ba1\u7406-\u76f8\u5173\u77e5\u8bc6&#xff08;\u7ec4\u7ec7\u901a\u7528\u6cbb\u7406\u3001\u7ec4\u7ec7\u901a\u7528\u7ba1\u7406\u3001\u6cd5\u5f8b\u6cd5\u89c4\u4e0e\u6807\u51c6\u89c4\u8303&#xff09;-CSDN\u535a\u5ba2<\/p>\n<hr \/>\n<p>Oracle\u5176\u4ed6\u6587\u6863&#xff0c;\u5e0c\u671b\u4e92\u76f8\u5b66\u4e60&#xff0c;<img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"45\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd61dece.png\" width=\"45\" \/>\u5171\u540c\u8fdb\u6b65<\/p>\n<p>Oracle-\u627e\u56de\u8bef\u5220\u7684\u8868\u6570\u636e(LogMiner \u6316\u6398\u65e5\u5fd7)_oracle\u65e5\u5fd7\u6316\u6398\u6062\u590d\u6570\u636e-CSDN\u535a\u5ba2<\/p>\n<p>oracle \u8ddf\u8e2a\u6587\u4ef6&#8211;\u5ba1\u8ba1\u65e5\u5fd7_oracle\u5ba1\u8ba1\u65e5\u5fd7-CSDN\u535a\u5ba2<\/p>\n<p>ORA-12899\u62a5\u9519&#xff0c;\u9047\u5230\u6570\u636e\u8868\u67d0\u5b57\u6bb5\u957f\u5ea6\u5947\u602a\u73b0\u8c61&#xff1a;\u201cOracle\u5b57\u7b26\u578b&#xff0c;\u957f\u5ea650\u201d\u4f46length\u67e5\u5374\u6ca1\u670950_varchar(50) oracle \u8d85\u51fa\u622a\u65ad-CSDN\u535a\u5ba2<\/p>\n<p>EXP-00091: Exporting questionable statistics.\u89e3\u51b3\u65b9\u6848-CSDN\u535a\u5ba2<\/p>\n<p>Oracle \u66f4\u6362\u76d1\u542c\u7aef\u53e3-CSDN\u535a\u5ba2<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Oracle &amp;&amp; OceanBase \u76f8\u5173\u6587\u6863&#xff0c;\u5e0c\u671b\u4e92\u76f8\u5b66\u4e60&#xff0c;\u5171\u540c\u8fdb\u6b65<br \/>\n\u98ce123456789&#xff5e;-CSDN\u535a\u5ba2 1.\u80cc\u666f \u6700\u8fd1\u5bf9\u6bd4\u4e24\u4e2a\u4e0d\u540c\u73af\u5883\u7684\u5e93\u65f6&#xff0c;\u53d1\u73b0\u591a\u51fa\u6765\u5f88\u591aSYS_C00107980 \u7684\u7ea6\u675f\u3002\u5c24\u5176\u662f\u751f\u4ea7\u6570\u636e\u5e93&#xff0c;\u547d\u540d\u6ca1\u6709\u6309\u7167\u89c4\u8303\u7ea6\u5b9a\u8d70\u3002 \u672c\u6587\u4e3b\u8981\u9488\u5bf9 oracle\u00a0 \u7ea6\u675f\u7684\u521b\u5efa\u3001\u547d\u540d\u3001\u9ed8\u8ba4\u540d\u79f0\u4fee\u6539&#xff0c;\u5229\u5f0a\u5206\u6790 \u53ca\u76f8\u5173\u77e5\u8bc6\u70b9\u6574\u7406\u3002<br \/>\n2.\u5b9e\u9a8c- \u521b\u5efa\u53ca\u4fee\u6539<br \/>\n2.1 \u6574\u4f53\u8bf4\u660e Oracle<\/p>\n","protected":false},"author":2,"featured_media":101294,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[604,100],"topic":[],"class_list":["post-101307","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-oracle","tag-100"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/101307.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"Oracle &amp;&amp; OceanBase \u76f8\u5173\u6587\u6863&#xff0c;\u5e0c\u671b\u4e92\u76f8\u5b66\u4e60&#xff0c;\u5171\u540c\u8fdb\u6b65 \u98ce123456789&#xff5e;-CSDN\u535a\u5ba2 1.\u80cc\u666f \u6700\u8fd1\u5bf9\u6bd4\u4e24\u4e2a\u4e0d\u540c\u73af\u5883\u7684\u5e93\u65f6&#xff0c;\u53d1\u73b0\u591a\u51fa\u6765\u5f88\u591aSYS_C00107980 \u7684\u7ea6\u675f\u3002\u5c24\u5176\u662f\u751f\u4ea7\u6570\u636e\u5e93&#xff0c;\u547d\u540d\u6ca1\u6709\u6309\u7167\u89c4\u8303\u7ea6\u5b9a\u8d70\u3002 \u672c\u6587\u4e3b\u8981\u9488\u5bf9 oracle\u00a0 \u7ea6\u675f\u7684\u521b\u5efa\u3001\u547d\u540d\u3001\u9ed8\u8ba4\u540d\u79f0\u4fee\u6539&#xff0c;\u5229\u5f0a\u5206\u6790 \u53ca\u76f8\u5173\u77e5\u8bc6\u70b9\u6574\u7406\u3002 2.\u5b9e\u9a8c- \u521b\u5efa\u53ca\u4fee\u6539 2.1 \u6574\u4f53\u8bf4\u660e Oracle\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/101307.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-06T07:57:11+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd61dece.png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/101307.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/101307.html\",\"name\":\"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-09-06T07:57:11+00:00\",\"dateModified\":\"2026-09-06T07:57:11+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/101307.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/101307.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/101307.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/101307.html","og_locale":"zh_CN","og_type":"article","og_title":"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"Oracle &amp;&amp; OceanBase \u76f8\u5173\u6587\u6863&#xff0c;\u5e0c\u671b\u4e92\u76f8\u5b66\u4e60&#xff0c;\u5171\u540c\u8fdb\u6b65 \u98ce123456789&#xff5e;-CSDN\u535a\u5ba2 1.\u80cc\u666f \u6700\u8fd1\u5bf9\u6bd4\u4e24\u4e2a\u4e0d\u540c\u73af\u5883\u7684\u5e93\u65f6&#xff0c;\u53d1\u73b0\u591a\u51fa\u6765\u5f88\u591aSYS_C00107980 \u7684\u7ea6\u675f\u3002\u5c24\u5176\u662f\u751f\u4ea7\u6570\u636e\u5e93&#xff0c;\u547d\u540d\u6ca1\u6709\u6309\u7167\u89c4\u8303\u7ea6\u5b9a\u8d70\u3002 \u672c\u6587\u4e3b\u8981\u9488\u5bf9 oracle\u00a0 \u7ea6\u675f\u7684\u521b\u5efa\u3001\u547d\u540d\u3001\u9ed8\u8ba4\u540d\u79f0\u4fee\u6539&#xff0c;\u5229\u5f0a\u5206\u6790 \u53ca\u76f8\u5173\u77e5\u8bc6\u70b9\u6574\u7406\u3002 2.\u5b9e\u9a8c- \u521b\u5efa\u53ca\u4fee\u6539 2.1 \u6574\u4f53\u8bf4\u660e Oracle","og_url":"https:\/\/www.wsisp.com\/helps\/101307.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-09-06T07:57:11+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260906075710-6a9d1cd61dece.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"5 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/101307.html","url":"https:\/\/www.wsisp.com\/helps\/101307.html","name":"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-09-06T07:57:11+00:00","dateModified":"2026-09-06T07:57:11+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/101307.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/101307.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/101307.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u3010Oracle\u4e13\u680f\u3011\u4e94\u7c7b\u7ea6\u675f\u547d\u540d &amp;&amp; \u5b9e\u8df5\u5efa\u8bae"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/101307","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=101307"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/101307\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/101294"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=101307"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=101307"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=101307"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=101307"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}