预定义异常(精)_第1页
预定义异常(精)_第2页
预定义异常(精)_第3页
全文预览已结束

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、Exceptio nOracle ErrorSQLCODE ValueACCESS_INTO_NULLORA-06530-6530CASE_NOT_FOUNDORA-06592-6592COLLECTION_IS_NULLORA-06531-6531CURSOR_ALREADY_OPENORA-06511-6511DUP_VAL_ON_INDEXORA-00001-1INVALID_CURSORORA-01001-1001INVALID_NUMBERORA-01722-1722LOGIN_DENIEDORA-01017-1017NO_DATA_FOUNDORA-01403+100NOT_LOG

2、GED_ONORA-01012-1012PROGRAM_ERRORORA-06501-6501ROWTYPE_MISMATCHORA-06504-6504SELF IS NULLORA-30625-30625STORAGE_ERRORORA-06500-6500SUBSCRIPT BEYOND COUNTORA-06533-6533SUBSCRIPT OUTSIDE LIMITORA-06532-6532SYS INVALID ROWIDORA-01410-1410TIMEOUT ON RESOURCEORA-00051-51TOO MANY ROWSORA-01422-1422VALUE E

3、RRORORA-06502-6502ZERO_DIVIDEORA-01476-1476Brief descriptions of the predefined exceptions follow:Exceptio nRaised whe n ACCESS_INTO_NULLYour program attempts to assign values to the attributes of an unin itialized (atomically n ull) object.CASE_NOT_FOUNDNone of the choices in the WHEN clauses of a

4、CASE statement is selected, and there is no ELSE clause.COLLECTION_IS_NULLYour program attempts to apply collecti onExceptio nRaised whe n methods other than EXISTSto an uninitialized (atomically nu II) n ested table or varray, or the program attempts to assign values to the eleme nts of an unin iti

5、alized n ested table or varray.CURSOR_ALREADY_OPENYour program attempts to open an already open cursor. A cursor must be closed before it can be reope ned. A cursor FOR loop automatically ope ns the cursor to which it refers. So, your program cannot ope n that cursor in side the loop.DUP_VAL_ON_INDE

6、XYour program attempts to store duplicate values in a database colu mn that is con stra ined by a unique in dex.INVALID_CURSORYour program attempts an illegal cursor operati on such as clos ing an un ope ned cursor.INVALID_NUMBERIn a SQL statement, the conversion of a character stri ng into a nu mbe

7、r fails because the string does not represent a valid number. (In procedural stateme nts, VALUE_ERROR is raised.) This excepti on is also raised whe n the LIMIT-clause expression in a bulk FETCH stateme nt does not evaluate to a positive nu mber.LOGIN_DENIEDYour program attempts to log on to Oracle

8、with an in valid user name an d/or password.NO_DATA_FOUNDA SELECT INTO stateme nt returns no rows, or your program refere nces a deleted eleme nt in a nested table or an uninitializedelement inan in dex-by table. SQL aggregate fun cti ons such as AVG and SUM always retur n a value or a null. So, a S

9、ELECTNTOstatement that calls an aggregate function n ever raises NO_DATA_FOUND. The FETCH stateme nt is expected to return no rows eventually,so whenthat happe ns, no excepti on is raised.NOT_LOGGED_ONYour program issues a database call without being conn ected to Oracle.Exceptio nRaised whe n PROGR

10、AM_ERRORPL/SQL has an internal problem.ROWTYPE_MISMATCHThe host cursor variable and PL/SQL cursor variable invo Ived in an assig nment have in compatible return types. For example, whe n an ope n host cursor variable is passed to a stored subprogram, the retur n types of the actual and formal parame

11、ters must be compatible.SELF_IS_NULLYour program attempts to call a MEMBEmethod on a n ull in sta nee. That is, the built-i n parameter SELF (which is always the first parameter passed to a MEMBER method) is null.STORAGE_ERRORPL/SQL runs out of memory or memory has bee n corrupted.SUBSCRIPT_BEYOND_C

12、OUNYour program refere nces a n ested table or varray eleme nt using an in dex nu mber larger tha n the nu mber of eleme nts in the collectio n.SUBSCRIPT_OUTSIDE_LIMITYour program refere nces a n ested table or varray eleme nt using an in dex nu mber (-1 for example) that is outside the legal ran ge

13、.SYS_INVALID_ROWIDThe conv ersi on of a character stri ng into a uni versal rowid fails because the character stri ng does not represe nt a valid rowid.TIMEOUT_ON_RESOURCEA time-out occurs while Oracle is waiting for a resource.TOO_MANY_ROWSA SELECTINTO statement returns more than one row.VALUE_ERRO

14、RAn arithmetic, conversion, truncation, or size-c on stra int error occurs. For example, when your program selects a column value into a character variable, if the value is Ion ger tha n the declared len gth of the variable, PL/SQL aborts the assig nment and raises VALUE_ERROR. In procedural stateme

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论