Flashcards
Sem título
Flashcards do conjunto (7)
- 1returns the numeric value of the left-most character of a string.ASCII( single_character )
mysql> SELECT ASCII('T2');
Result: 84 - 2returns the length of the specified string (measured in characters).CHAR_LENGTH( string ) ou
CHARACTER_LENGTH( string )
mysql> SELECT CHAR_LENGTH('a 2');
Result: 3 - 3allows you to concatenate two or more expressions together.CONCAT( exp1, exp2, ... expN )
mysql> SELECT CONCAT('x = ', 10+10);
Result: 'x = 20' - 4allows you to concatenate two or more expressions together and adds a separator between each of the concatenated expressions.CONCAT_WS( separ, exp1, exp2, ... expN )
mysql> SELECT CONCAT('AA', 'x', 10+10);
Result: 'xAA20'
skips null exps
separator null => null - 5returns the position of a value in a list of values (val1, val2, val3, ...).FIELD( value, val1, val2, val3, ... )
mysql> SELECT FIELD('b', 'a', 'b');
Result: 2
value not found or null => 0 - 6returns the position of a string in a comma-delimited string list. (case insensitive)FIND_IN_SET( string, string_list )
mysql> SELECT FIND_IN_SET('B', 'a,b');
Result: 2
string not found or string_list empty => 0
string or string_list null => null - 7—
Informações
- Descrição
- Concurso Público Bancos de Dados FlashCards sobre Sem título, criado por dgmagno em 16-02-2016.
- Criado por
- dgmagno
- Visualizações
- 0
- Avaliação