aboutsummaryrefslogtreecommitdiffstats
path: root/yql/essentials/tests/sql/suites/blocks/string_len_and_cmp.sql
blob: 6450080bd55ef6ba0bcf20803a80ecb0fce294f3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
USE plato;

SELECT
    key,

    value       == value_utf,
    value_utf   != value,
    value        < value_utf,
    value_utf   <= value_utf,
    value        > value_utf,
    value_utf   >= value_utf,

    value       == 'foo',
    'foo'       != value,
    value        < 'foo',
    'тест'      <= value_utf,
    value        > 'foo',
    'проверка'u >= value_utf,

    ''          == value_utf,
    ''          != value,
    ''           < value_utf,
    ''          <= value_utf,
    ''           > value_utf,
    ''          >= value_utf,

    value       == ''u,
    value_utf   != ''u,
    value        < ''u,
    value_utf   <= ''u,
    value        > ''u,
    value_utf   >= ''u,

    len(value),
    len(value_utf),
    len(''),
    len(''u),
    len('проверка'),
    len('тест'u),

FROM Input
ORDER BY key