We're Moving!

The Vertica Forum is moving to a new OpenText Analytics Database (Vertica) Community.

Join us there to post discussion topics, learn about

product releases, share tips, access the blog, and much more.

Create My New Community Account Now


Summarize a Table’s Projections — Vertica Forum

Summarize a Table’s Projections

Jim Knicely authored this tip.

Use the built-in Vertica function GET_TABLE_PROJECTIONS to quickly summarize the details of all of the projections of a Vertica table.

Example:

dbadmin=> \a
Output format is unaligned.

dbadmin=> \t
Showing only tuples.

dbadmin=> SELECT get_table_projections('public.jim');
Current system K is 1.
# of Nodes: 3.
Table public.jim has 3 projections.

Projection Name: [Segmented] [Seg Cols] [# of Buddies] [Buddy Projections] [Safe] [UptoDate] [Stats]
----------------------------------------------------------------------------------------------------
public.jim_replicate [Segmented: No] [Seg Cols: ] [K: 2] [public.jim_replicate] [Safe: Yes] [UptoDate: Yes] [Stats: Yes]
public.jim_b1 [Segmented: Yes] [Seg Cols: "public.jim.c1", "public.jim.c2"] [K: 1] [public.jim_b0] [Safe: Yes] [UptoDate: Yes] [Stats: Yes]
public.jim_b0 [Segmented: Yes] [Seg Cols: "public.jim.c1", "public.jim.c2"] [K: 1] [public.jim_b1] [Safe: Yes] [UptoDate: Yes] [Stats: Yes]

Have fun!

Sign In or Register to comment.