Oracle/PLSQL: Lpad and Rpad Function
Oracle/PLSQL: Lpad Function:
http://www.techonthenet.com/oracle/functions/lpad.php
RPAD and LPAD [Oracle SQL]:
http://www.adp-gmbh.ch/ora/sql/rpad.html
引述
In Oracle/PLSQL, the lpad function pads the left-side of a string with a specific set of characters.
The syntax for the lpad function is:
lpad( string一, padded_length, [ pad_string ] )
string一 is the string to pad characters to (the left-hand side).
padded_length is the number of characters to return. If the padded_length is smaller than the original string, the lpad function will truncate the string to the size of padded_length.
pad_string is optional. This is the string that will be padded to the left-hand side of string1. If this parameter is omitted, the lpad function will pad spaces to the left-side of string1.
Applies To:
Oracle 八i, Oracle 九i, Oracle 十g, Oracle 11g
For example:
lpad('tech', 七); would return ' tech'
lpad('tech', 二); would return 'te'
lpad('tech', 八, '零'); would return '0000tech'
lpad('tech on the net', 15, 'z'); would return 'tech on the net'
lpad('tech on the net', 16, 'z'); would return 'ztech on the net'
本文来源:
我的异常网
Java Exception
Dotnet Exception
Oracle Exception
2556 - sql检索文中字段相等判断
2557 - ORA-12535: TNS:operation timed out
2558 - oracle增量导入更新
2559 - Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
2560 - the account is locked
2561 - 使用exp备份文件用当前日期做为文件名
2562 - sqlplus怎么看表的建立时间
2563 - oracle测试存储过程plsql无响应
2564 - ORA-01403: no data found
2565 - ORACLE存储过程写法
2566 - 怎样在服务里添加 OracleOraHome92TNSListener
2567 - 游标嵌套使用
2568 - ORA-01031 instufficent privileges
2569 - SQLPLUS导出数据换行
2570 - ORA-12154: TNS: 无法解析指定的连接标识符
2571 - oracle里对应mssql里addday()的函数是什么
2572 - 企业管理器上是否能实现备份
2573 - 如何在Oracle中建立作业
2574 - 怎么使用嵌套表
2575 - 怎么定义嵌套表
相关文档:
先root打补丁:p3006854_9204_linux.zip
再设oracle环境变量
安装
安装结束建库之前需要打的补丁有:
p2617419_220_GENERIC.zip
p3119415_9204_linux.zip
具体参考这篇文章:
Redhat Enterprise Linux 4安装oracle
关键字: redhat el4 oracle 安装
一. 安装准备
1. as4安装完后,需要检查下列软件 ......
## Oracle 数据导入到 Mysql ##
__________________________________________ ......
-- 查询某表的数据字典
SELECT A.TABLE_NAME AS "表名",A.COLUMN_NAME AS "字段名",
DECODE(A.CHAR_LENGTH,0,DECODE(A.DATA_SCALE,NULL,A.DATA_TYPE,A.DATA_TYPE||'('||A.DATA_PRECISION||','||A.DATA_SCALE||')'),
A.DATA_TYPE||'('||A.CHAR_LENGTH||')') as "字段类型1",A.DATA_TYPE AS "字段 ......
使用ultraedit32打开导出的dmp文件,文件内容以十六进制显示数据,其中第二、三字节的数据记录的是此文件的字符集。
例如:
03 54
将其转换为10进制,值为852,使用命令
select nls_charset_name(852) from dual
得到结果
ZHS16GBK
当前使用winXP简体中文操作系统,Oracle客户端默认字符集为GBK。
创建数据库,设定 ......
用oracle的卸载程序并不能完全卸载干净。如之前的命名的oracle sid 不能再使用。会提示sid存在。下面是在winxp下完全卸载oracle的方法。
1、开始->设置->控制面板->管理工具->服务
停止所有Oracle服务。
2、开始->程序->Oracle - OraHome81->Oracle ......