ORACLE/PLSQL: TRIM FUNCTION
来源:互联网 发布:电商美工的前景 编辑:程序博客网 时间:2024/06/08 10:01
The Oracle/PLSQL TRIM function removes all specified characters either from the beginning or the ending of a string.
ORACLE TRIM SYNTAX
The syntax for the Oracle/PLSQL TRIM function is:
TRIM( [ leading | trailing | both [ trim_character ] string1 )
PARAMETERS OR ARGUMENTS
leading - remove trim_string from the front of string1.
trailing - remove trim_string from the end of string1.
both - remove trim_string from the front and end of string1.
trim_character is the character that will be removed from string1. If this parameter is omitted, the TRIM function will remove all leading and trailing spaces fromstring1.
string1 is the string to trim.
NOTE
If you do not choose a value for the first parameter (leading, trailing, both), the TRIM function will remove trim_string from both the front and end of string1.
APPLIES TO
The TRIM function can be used in the following versions of Oracle/PLSQL:
- Oracle 12c, Oracle 11g, Oracle 10g, Oracle 9i, Oracle 8i
ORACLE TRIM EXAMPLE
Let's look at some Oracle TRIM function examples and explore how you would use the TRIM function in Oracle/PLSQL.
For example:
TRIM(' tech ')would return 'tech'TRIM(' ' from ' tech ')would return 'tech'TRIM(leading '0' from '000123')would return '123'TRIM(trailing '1' from 'Tech1')would return 'Tech'TRIM(both '1' from '123Tech111')would return '23Tech'- ORACLE/PLSQL: TRIM FUNCTION
- Oracle/PLSQL: NVL Function
- Oracle/PLSQL: Decode Function
- Oracle/PLSQL: Sign Function
- Oracle/PLSQL: Extract Function
- Oracle/PLSQL: Replace Function
- Oracle pl/sql trim function
- Oracle/PLSQL: To_Char Function[转贴]
- Oracle/PLSQL: Lpad and Rpad Function
- Oracle/PLSQL: Trunc Function (with dates)
- oracle创建trigger procedure function sequence plsql
- PLSQL Function
- c++ trim function string
- function trim() 问题
- ORACLE TRIM
- iphone trim trimStart trimEnd function
- PLSQL to_char function
- PLSQL通用 分页 Function
- HDOJ-2026
- Ubuntu打开终端的方法三种
- 用shell将时间字符串与时间戳互转
- IOS开发之UIWebView实际应用(一)
- POJ 1258 Agri-Net(最小生成树 Prim 模版题)
- ORACLE/PLSQL: TRIM FUNCTION
- 对比 NFC,Apple iOS 7 类似解决方案 iBeacons 的优缺点
- 会话COOKIE 持久COOKIE
- SQLite加密
- VC中用于调试程序的几个宏的使用技巧
- 类内的类型转换
- JavaScript正则表达式
- CentOS6 Linux下mail命令配置及使用
- 【REST WCF】