-
Notifications
You must be signed in to change notification settings - Fork 591
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
876ef34
commit a006ada
Showing
8 changed files
with
204 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -268,3 +268,62 @@ SELECT * from person_new order by id; | |
1100 noris [email protected] 1864 2539 enne | ||
1101 white [email protected] 8157 6974 se | ||
1102 spencer [email protected] 9481 6270 angeles | ||
|
||
statement ok | ||
CREATE TABLE numeric_to_rw_int256_shared ( | ||
id int, | ||
num rw_int256, | ||
PRIMARY KEY (id) | ||
) FROM pg_source TABLE 'public.numeric_table'; | ||
|
||
statement ok | ||
CREATE TABLE numeric_to_varchar_shared ( | ||
id int, | ||
num varchar, | ||
PRIMARY KEY (id) | ||
) FROM pg_source TABLE 'public.numeric_table'; | ||
|
||
|
||
system ok | ||
psql -c " | ||
insert into numeric_table values(102, 57896044618658097711785492504343953926634992332820282019728792003956564819967); | ||
--- 2^255 | ||
insert into numeric_table values(103, 57896044618658097711785492504343953926634992332820282019728792003956564819968); | ||
--- 2^256 | ||
insert into numeric_table values(104, 115792089237316195423570985008687907853269984665640564039457584007913129639936); | ||
insert into numeric_table values(105, 115792089237316195423570985008687907853269984665640564039457584007913129639936.555555); | ||
" | ||
|
||
sleep 3s | ||
|
||
query III rowsort | ||
select * from numeric_to_varchar_shared | ||
---- | ||
1 3.14 | ||
102 57896044618658097711785492504343953926634992332820282019728792003956564819967 | ||
103 57896044618658097711785492504343953926634992332820282019728792003956564819968 | ||
104 115792089237316195423570985008687907853269984665640564039457584007913129639936 | ||
105 115792089237316195423570985008687907853269984665640564039457584007913129639936.555555 | ||
2 57896044618658097711785492504343953926634992332820282019728792003956564819967 | ||
3 57896044618658097711785492504343953926634992332820282019728792003956564819968 | ||
4 115792089237316195423570985008687907853269984665640564039457584007913129639936 | ||
5 115792089237316195423570985008687907853269984665640564039457584007913129639936.555555 | ||
|
||
# The invalid data for rw_int256 is converted to NULL | ||
query III rowsort | ||
select * from numeric_to_rw_int256_shared | ||
---- | ||
1 NULL | ||
102 57896044618658097711785492504343953926634992332820282019728792003956564819967 | ||
103 NULL | ||
104 NULL | ||
105 NULL | ||
2 57896044618658097711785492504343953926634992332820282019728792003956564819967 | ||
3 NULL | ||
4 NULL | ||
5 NULL | ||
|
||
system ok | ||
psql -c " | ||
DELETE FROM numeric_table WHERE id IN (102, 103, 104, 105); | ||
" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters