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 - 怎么定义嵌套表