Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
b036982d
Commit
b036982d
authored
Apr 17, 2019
by
Alvaro Herrera
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
psql: display tablespace for partitioned indexes
Nothing was shown previously.
parent
fb9c4755
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
1 deletion
+11
-1
src/bin/psql/describe.c
src/bin/psql/describe.c
+2
-1
src/test/regress/input/tablespace.source
src/test/regress/input/tablespace.source
+1
-0
src/test/regress/output/tablespace.source
src/test/regress/output/tablespace.source
+8
-0
No files found.
src/bin/psql/describe.c
View file @
b036982d
...
...
@@ -3306,7 +3306,8 @@ add_tablespace_footer(printTableContent *const cont, char relkind,
if
(
relkind
==
RELKIND_RELATION
||
relkind
==
RELKIND_MATVIEW
||
relkind
==
RELKIND_INDEX
||
relkind
==
RELKIND_PARTITIONED_TABLE
)
relkind
==
RELKIND_PARTITIONED_TABLE
||
relkind
==
RELKIND_PARTITIONED_INDEX
)
{
/*
* We ignore the database default tablespace so that users not using
...
...
src/test/regress/input/tablespace.source
View file @
b036982d
...
...
@@ -63,6 +63,7 @@ CREATE INDEX part_a_idx ON testschema.part (a) TABLESPACE regress_tblspace;
CREATE TABLE testschema.part2 PARTITION OF testschema.part FOR VALUES IN (2);
SELECT relname, spcname FROM pg_catalog.pg_tablespace t, pg_catalog.pg_class c
where c.reltablespace = t.oid AND c.relname LIKE 'part%_idx';
\d testschema.part_a_idx
-- check that default_tablespace doesn't affect ALTER TABLE index rebuilds
CREATE TABLE testschema.test_default_tab(id bigint) TABLESPACE regress_tblspace;
...
...
src/test/regress/output/tablespace.source
View file @
b036982d
...
...
@@ -94,6 +94,14 @@ SELECT relname, spcname FROM pg_catalog.pg_tablespace t, pg_catalog.pg_class c
part_a_idx | regress_tblspace
(3 rows)
\d testschema.part_a_idx
Partitioned index "testschema.part_a_idx"
Column | Type | Key? | Definition
--------+---------+------+------------
a | integer | yes | a
btree, for table "testschema.part"
Tablespace: "regress_tblspace"
-- check that default_tablespace doesn't affect ALTER TABLE index rebuilds
CREATE TABLE testschema.test_default_tab(id bigint) TABLESPACE regress_tblspace;
INSERT INTO testschema.test_default_tab VALUES (1);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment