citusdata / citusdata/cstore_fdw
truncating a partitioned table with cstore_fdw partitions fail
- Dominant language
- C
- Stars
- 1.8k
- Forks
- 169
- PR merge metrics
- No merged PRs in 30d
Description
That is probably due to us handling truncate command via process utility.
Note : Postgres does support truncating foreign tables. So we hook into process utility and modify truncate command to remove any cstore_fdw tables in it. Then we do our internal truncation.
Repro steps
```sql
create table pp(a int, b int) partition by range(a);
create table p1 partition of pp for values from (1) to (10);
create foreign table c1 partition of pp for values from (10) to (20) server cstore_server;
insert into pp values (1,1);
select * from pp;
truncate pp; -- will fail with ERROR: "c1" is not a table
-- see truncate on regular table partition is not performed either
select * from pp;
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.