Oracle 5.0 Reference Manual page 913

Table of Contents

Advertisement

Returns the string str, right-padded with the string
longer than len, the return value is shortened to
mysql>
SELECT RPAD('hi',5,'?');
-> 'hi???'
mysql>
SELECT RPAD('hi',1,'?');
-> 'h'
This function is multi-byte safe.
[893]
RTRIM(str)
Returns the string
str
mysql>
SELECT RTRIM('barbar
-> 'barbar'
This function is multi-byte safe.
[893]
SOUNDEX(str)
Returns a soundex string from str. Two strings that sound almost the same should have identical
soundex strings. A standard soundex string is four characters long, but the
function returns an arbitrarily long string. You can use
standard soundex string. All nonalphabetic characters in
characters outside the A-Z range are treated as vowels.
Important
When using
limitations:
• This function, as currently implemented, is intended to work well with strings that are in the English
language only. Strings in other languages may not produce reliable results.
• This function is not guaranteed to provide consistent results with strings that use multi-byte
character sets, including utf-8.
We hope to remove these limitations in a future release. See Bug #22638 for more information.
mysql>
SELECT SOUNDEX('Hello');
-> 'H400'
mysql>
SELECT SOUNDEX('Quadratically');
-> 'Q36324'
Note
This function implements the original Soundex algorithm, not the more
popular enhanced version (also described by D. Knuth). The difference is
that original version discards vowels first and duplicates second, whereas the
enhanced version discards duplicates first and vowels second.
expr1 SOUNDS LIKE expr2
This is the same as
SOUNDEX(expr1) = SOUNDEX(expr2)
[893]
SPACE(N)
Returns a string consisting of
mysql>
SELECT SPACE(6);
-> '
'
String Functions
with trailing space characters removed.
');
[893], you should be aware of the following
SOUNDEX()
[893]
space characters.
N
893
to a length of
padstr
characters.
len
[894]
SUBSTRING()
are ignored. All international alphabetic
str
[893].
characters. If
len
str
[893]
SOUNDEX()
on the result to get a
is

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents