Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CREATE TABLE my_table1
- (
- id BigSerial NOT NULL,
- LENGTH UInt32,
- ama Utf8,
- ama1 DECIMAL(22,9),
- ama2 DyNumber,
- PRIMARY KEY (id)
- );
- $ama = "123456789012345678901234567890"; -- 30
- INSERT INTO my_table1 (LENGTH, ama, ama1, ama2) VALUES (Unwrap(len($ama)), $ama, DECIMAL($ama, 22, 9), DyNumber($ama));
- $ama = "1234567890123456789012345"; -- 25
- INSERT INTO my_table1 (LENGTH, ama, ama1, ama2) VALUES (Unwrap(len($ama)), $ama, DECIMAL($ama, 22, 9), DyNumber($ama));
- $ama = "123456789012345"; -- 15
- INSERT INTO my_table1 (LENGTH, ama, ama1, ama2) VALUES (Unwrap(len($ama)), $ama, DECIMAL($ama, 22, 9), DyNumber($ama));
- $ama = "12345678901234"; -- 14
- INSERT INTO my_table1 (LENGTH, ama, ama1, ama2) VALUES (Unwrap(len($ama)), $ama, DECIMAL($ama, 22, 9), DyNumber($ama));
- $ama = "1234567890123"; -- 13
- INSERT INTO my_table1 (LENGTH, ama, ama1, ama2) VALUES (Unwrap(len($ama)), $ama, DECIMAL($ama, 22, 9), DyNumber($ama));
- $ama = "1234567890"; -- 10
- INSERT INTO my_table1 (LENGTH, ama, ama1, ama2) VALUES (Unwrap(len($ama)), $ama, DECIMAL($ama, 22, 9), DyNumber($ama));
- -- Результат inf:
- SELECT
- SUM(ama1) AS s2,
- --sum(ama2) as s3 -- Unsupported column type: DyNumber
- FROM my_table1;
- -- Результат число:
- SELECT
- SUM(ama1) AS s2,
- --sum(ama2) as s3 -- Unsupported column type: DyNumber
- FROM my_table1 WHERE LENGTH < 14;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement