Documentation

CHAR

Char() function takes an integer ascii code and returns a string containing the character represented by that code.

Syntax

char(int_expr)

Arguments

int_expr An integer from 0 through 255.

Return Type

string

Return Value

char() returns the string symbol that represents the int_expr

Remarks

None

Examples

A. Char function on a column.

create table segments
    (_id id, segment string, ascii_number int);

insert into segments(_id, segment, ascii_number)
    values (1,'red', 114)

select _id, segment, char(ascii_number) as num from segments;
+-----+----------+------+
| _id | segment  | num  |
+-----+----------+------+
|   1 | red      | r    |
+-----+----------+------+
Something missing or incorrect?
Help improve this article or join us on Discord!

© 2022 Molecula Corp. (DBA FeatureBase). All rights reserved.