Oracle SQL(二) 条件表达式 CASE 语句 或者DECODE 函数,两者均可实现 IF-THEN-ELSE 的逻辑,相比较而言,DECODE 更加简洁 SELECT last_name ,job_id ,salary ,CASE job_id WHEN 'IT_PROG' THEN 1.10 * salary WHEN 'ST_CLERK' THEN 1.15 * salary WHEN 'SA_REP' THEN 1.20 * salary ELSE salary END as "…
1. 在ORACLE官网下载Oracle SQL Developer第三方数据库驱动 下载页面:http://www.oracle.com/technetwork/developer-tools/sql-developer/thirdparty-095608.html Download the MySQL Drivers from the MySQL Site. There are two drivers here: 1) MySQL Connector/j 5.0 Unzip the zip…
From http://blog.csdn.net/wujiandao/article/details/6621073 1. Four ways to get execution plan(anytime you want, for specified sql) • Execute the SQL statement EXPLAIN PLAN, and then query the table where the output was written. • Query a dynamic per…
处理oracle sql 语句in子句中(where id in (1, 2, ..., 1000, 1001)),如果子句中超过1000项就会报错.这主要是oracle考虑性能问题做的限制.如果要解决次问题,可以用 where id (1, 2, ..., 1000) or id (1001, ...) package windy.learn; import java.util.Collection; import org.apache.commons.lang3.StringUtils; p…
sqlldr工具 SQL*Loader的客户端工具是sqlldr,在操作系统的命令行下输入sqlldr,后面不接任何参数,将显示帮助信息如下所示(所有命令行参数的简单描述及其默认值),所以你并不需要对下面的参数死记硬背,当你忘记它们时,可以通过这个方式快速查询. Valid Keywords: userid -- ORACLE username/password control -- control file name log -- log file name bad -- bad file…
Oracle SQL Developer连接报错(ORA-12505) 之前我的Oracle数据库出现问题,费大波周折终于弄好了,今天又创建了一个DBA管理员的连接方式出现问题,本人现在把解决方案分享给大家,希望对你们有用. 连接时报错码:Listener refused the connection with following error:ORA-12505,TNS:listener...... 确定这是连接数据库的SID错误, 解决方法: 1.知道你的SID名:可以再注册表中查找,也可以通…
oracle sql日期比较:在今天之前: select * from up_date where update < to_date('2007-09-07 00:00:00','yyyy-mm-dd hh24:mi:ss')select * from up_date where update <= to_date('2007-09-07 00:00:00','yyyy-mm-dd hh24:mi:ss') 在今天只后: select * from up_date where update &…
本文转自:http://www.oracle.com/technetwork/cn/server-storage/linux/sqldev-adv-otn-092384.html Advanced Oracle SQL Developer Features < Do not delete this text because it is a placeholder for the generated list of "main" topics when run in a brows…
一.错误描述: 此错误导致了web 服务器停止服务,应该属于“不能连接Oracle”的错误. 二.具体错误信息: 信息: Illegal access: this web application instance has been stopped already. Could not load oracle/sql/converter_xcharset/lx20354.glb. The eventual following stack trace is caused by an error…
SQL RIGHT JOIN 关键字 RIGHT JOIN 关键字会右表 (table_name2) 那里返回所有的行,即使在左表 (table_name1) 中没有匹配的行. RIGHT JOIN 关键字语法 SELECT column_name(s) FROM table_name1 RIGHT JOIN table_name2 ON table_name1.column_name=table_name2.column_name 注释:在某些数据库中, RIGHT JOIN 称为 RIGHT…
SQL LEFT JOIN 关键字 LEFT JOIN 关键字会从左表 (table_name1) 那里返回所有的行,即使在右表 (table_name2) 中没有匹配的行. LEFT JOIN 关键字语法 SELECT column_name(s) FROM table_name1 LEFT JOIN table_name2 ON table_name1.column_name=table_name2.column_name 注释:在某些数据库中, LEFT JOIN 称为 LEFT OUTE…