Oracle 5.0 Reference Manual page 911

Table of Contents

Advertisement

mysql>
SET @str = BINARY 'New York';
mysql>
SELECT LOWER(@str), LOWER(CONVERT(@str USING latin1));
+-------------+-----------------------------------+
| LOWER(@str) | LOWER(CONVERT(@str USING latin1)) |
+-------------+-----------------------------------+
| New York
| new york
+-------------+-----------------------------------+
This function is multi-byte safe.
LPAD(str,len,padstr)
Returns the string str, left-padded with the string
longer than len, the return value is shortened to
mysql>
SELECT LPAD('hi',4,'??');
-> '??hi'
mysql>
SELECT LPAD('hi',1,'??');
-> 'h'
[891]
LTRIM(str)
Returns the string
str
mysql>
SELECT LTRIM('
-> 'barbar'
This function is multi-byte safe.
MAKE_SET(bits,str1,str2,...)
Returns a set value (a string containing substrings separated by "," characters) consisting of the
strings that have the corresponding bit in
on.
values in str1, str2,
NULL
mysql>
SELECT MAKE_SET(1,'a','b','c');
-> 'a'
mysql>
SELECT MAKE_SET(1 | 4,'hello','nice','world');
-> 'hello,world'
mysql>
SELECT MAKE_SET(1 | 4,'hello','nice',NULL,'world');
-> 'hello'
mysql>
SELECT MAKE_SET(0,'a','b','c');
-> ''
MID(str,pos,len)
MID(str,pos,len)
[891]
OCT(N)
Returns a string representation of the octal value of N, where
is equivalent to
CONV(N,10,8)
mysql>
SELECT OCT(12);
-> '14'
OCTET_LENGTH(str)
[891]
OCTET_LENGTH()
[891]
ORD(str)
If the leftmost character of the string
character, calculated from the numeric values of its constituent bytes using this formula:
(1st byte code)
String Functions
[891]
with leading space characters removed.
barbar');
[891]
bits
are not appended to the result.
...
[891]
[891]
is a synonym for
SUBSTRING(str,pos,len)
[909]. Returns
[891]
is a synonym for
LENGTH()
is a multi-byte character, returns the code for that
str
891
|
to a length of
padstr
characters.
len
set.
corresponds to bit 0,
str1
is a longlong (BIGINT) number. This
N
if
is NULL.
NULL
N
[890].
characters. If
len
str
to bit 1, and so
str2
[894].
is

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents