📄 errorcode.out
字号:
ij> ---- this test shows the error code functionality---- specify an invalid driverdriver 'java.lang.Integer';IJ ERROR: Could not locate class java.lang.Integerij> -- now a valid driverdriver 'org.apache.derby.jdbc.EmbeddedDriver';ij> -- specify an invalid databaseconnect 'asdfasdf';ERROR 08001: No suitable driver (errorCode = 0)ij> -- now a valid database, but no createconnect 'jdbc:derby:wombat';ERROR XJ004: Database 'wombat' not found. (errorCode = 40000)ij> -- now a valid databaseconnect 'jdbc:derby:wombat;create=true';ij> -- create the tablecreate table t(i int, s smallint);0 rows inserted/updated/deletedij> -- populate the tableinsert into t values (1,2);1 row inserted/updated/deletedij> insert into t values (null,2);1 row inserted/updated/deletedij> -- parser error-- bug 5701create table t(i nt, s smallint);ERROR 42X01: Syntax error: Encountered "" at line 3, column 18. (errorCode = 30000)ij> -- non-boolean where clauseselect * from t where i;ERROR 42X19: The WHERE or HAVING clause or CHECK CONSTRAINT definition is a 'INTEGER' expression. It must be a BOOLEAN expression. (errorCode = 30000)ij> -- invalid correlation name for "*"select asdf.* from t;ERROR 42X10: 'ASDF' is not an exposed table name in the scope in which it appears. (errorCode = 30000)ij> -- execution time errorselect i/0 from t;1 -----------ERROR 22012: Attempt to divide by zero. (errorCode = 30000)ij> -- test ErrorMessages VTIselect * from new org.apache.derby.diag.ErrorMessages() c where sql_state = '07000';SQL_&|MESSAGE |SEVERITY --------------------------------------------------------------------------------------------------------------------------------------------------07000|At least one parameter to the current statement is uninitialized. |20000 ij> select * from new org.apache.derby.diag.ErrorMessages() c where sql_state = '22012';SQL_&|MESSAGE |SEVERITY --------------------------------------------------------------------------------------------------------------------------------------------------22012|Attempt to divide by zero. |20000 ij> select * from new org.apache.derby.diag.ErrorMessages() c where sql_state = '42X74';SQL_&|MESSAGE |SEVERITY --------------------------------------------------------------------------------------------------------------------------------------------------42X74|Invalid CALL statement syntax. |20000 ij> -- cleanupdrop table t;0 rows inserted/updated/deletedij>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -