DROP schema "BFST" RESTRICT 異常
提示信息:
[Code: -478, SQL State: 42893] DB2 SQL Error: SQLCODE=-478, SQLSTATE=42893, SQLERRMC=SCHEMA;BFST.SEQ_ACCLOG_SEQNO;SEQUENCE, DRIVER=4.19.49
原因: 是否存在依賴該schema 的Functions, Sequences.......
解決方案: 先刪除該schema中的Functions, Sequences; 然後在刪除對應的schema
查找方法問題的過程:
登錄db2數據庫服務器
切換到db2inst1或其他dbadm權限的賬戶,命令: su - dbinst1
執行兩句命令: 1. db2 2. DROP schema "BFST" RESTRICT
提示信息: DB21034E The command was processed as an SQL statement because it was not a
valid Command Line Processor command. During SQL processing it returned:
SQL0478N The statement failed because one or more dependencies exist on the
target object. Target object type: "SCHEMA". Name of an object that is
dependent on the target object: "BFGL.SQL200611134016565". Type of object that
is dependent on the target object: "FUNCTION". SQLSTATE=42893