mirror of https://github.com/citusdata/citus.git
Improve COPY shard-pruning test
parent
83c83fdf1a
commit
2a8121ca5f
|
@ -135,7 +135,8 @@ WHERE shardid = :new_shard_id;
|
||||||
COPY customer_copy_range FROM '@abs_srcdir@/data/customer.1.data' WITH (DELIMITER '|');
|
COPY customer_copy_range FROM '@abs_srcdir@/data/customer.1.data' WITH (DELIMITER '|');
|
||||||
|
|
||||||
-- Check whether data went into the right shard (maybe)
|
-- Check whether data went into the right shard (maybe)
|
||||||
SELECT count(*) FROM customer_copy_range WHERE c_custkey = 1;
|
SELECT min(c_custkey), max(c_custkey), avg(c_custkey), count(*)
|
||||||
|
FROM customer_copy_range WHERE c_custkey <= 500;
|
||||||
|
|
||||||
-- Check whether data was copied
|
-- Check whether data was copied
|
||||||
SELECT count(*) FROM customer_copy_range;
|
SELECT count(*) FROM customer_copy_range;
|
||||||
|
|
|
@ -158,10 +158,11 @@ WHERE shardid = :new_shard_id;
|
||||||
-- Test copy into range-partitioned table
|
-- Test copy into range-partitioned table
|
||||||
COPY customer_copy_range FROM '@abs_srcdir@/data/customer.1.data' WITH (DELIMITER '|');
|
COPY customer_copy_range FROM '@abs_srcdir@/data/customer.1.data' WITH (DELIMITER '|');
|
||||||
-- Check whether data went into the right shard (maybe)
|
-- Check whether data went into the right shard (maybe)
|
||||||
SELECT count(*) FROM customer_copy_range WHERE c_custkey = 1;
|
SELECT min(c_custkey), max(c_custkey), avg(c_custkey), count(*)
|
||||||
count
|
FROM customer_copy_range WHERE c_custkey <= 500;
|
||||||
-------
|
min | max | avg | count
|
||||||
1
|
-----+-----+----------------------+-------
|
||||||
|
1 | 500 | 250.5000000000000000 | 500
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
-- Check whether data was copied
|
-- Check whether data was copied
|
||||||
|
|
Loading…
Reference in New Issue