aboutsummaryrefslogtreecommitdiffstats
path: root/yql/essentials/tests/sql/suites/blocks/decimal_multiplicative_ops.sql
blob: 4d3166b6a582e387394a56f275055eb61c866d98 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
USE plato;

SELECT
    cs_ext_list_price,  cs_ext_tax,
    cs_ext_list_price * cs_ext_tax, cs_ext_list_price * Just(decimal("13.37", 7, 2)), Just(decimal("42.0", 7, 2)) * cs_ext_tax,
                                    cs_ext_list_price * decimal("13.37", 7, 2), decimal("42.0", 7, 2) * cs_ext_tax,

    cs_ext_list_price / cs_ext_tax, cs_ext_list_price / Just(decimal("13.37", 7, 2)), Just(decimal("42.0", 7, 2)) / cs_ext_tax,
                                    cs_ext_list_price / decimal("13.37", 7, 2), decimal("42.0", 7, 2) / cs_ext_tax,
    
    cs_ext_list_price % cs_ext_tax, cs_ext_list_price % Just(decimal("13.37", 7, 2)), Just(decimal("42.0", 7, 2)) % cs_ext_tax,
                                    cs_ext_list_price % decimal("13.37", 7, 2), decimal("42.0", 7, 2) % cs_ext_tax,

    cs_ext_list_price * Just(13), cs_ext_list_price * 13,
    cs_ext_list_price / Just(13), cs_ext_list_price / 13,
    cs_ext_list_price % Just(13), cs_ext_list_price % 13,
FROM Input;