Hey I am looking for command to watch already made tables for example i got table called 'foo'
I want command to show me foo fields like:
CREATE table foo(
id int,
name varchar(10)
partition, group by.... etc.
Look at the table schema.
Moderator: NorbertKrupa
Re: Look at the table schema.
To view the table fields you can use
-> \d tablename
This will give you the columns of the table.
To see the list of table use
-> \dt
This will give you all the tables under a user
-> \d tablename
This will give you the columns of the table.
To see the list of table use
-> \dt
This will give you all the tables under a user
-
- GURU
- Posts: 527
- Joined: Tue Oct 22, 2013 9:36 pm
- Location: Chicago, IL
- Contact:
Re: Look at the table schema.
If you're looking for the actual DDL of the table, then you can use the EXPORT_TABLES() function:
Code: Select all
SELECT EXPORT_TABLES(' ','store.store_orders_fact');
Checkout vertica.tips for more Vertica resources.
-
- Newbie
- Posts: 15
- Joined: Tue Aug 26, 2014 1:43 pm
Re: Look at the table schema.
Thanks all.