Max columns for FLEX table?

Moderator: NorbertKrupa

Post Reply
User avatar
usli06
Intermediate
Intermediate
Posts: 93
Joined: Wed Jan 25, 2012 4:53 am

Max columns for FLEX table?

Post by usli06 » Thu Feb 02, 2017 3:52 pm

Hello,

Is there a maximum number of columns for a FLEX table?

Thanks!

User avatar
JimKnicely
Site Admin
Site Admin
Posts: 1825
Joined: Sat Jan 21, 2012 4:58 am
Contact:

Re: Max columns for FLEX table?

Post by JimKnicely » Thu Feb 02, 2017 5:29 pm

Hi,

There is a 1600 column limit.

See: https://my.vertica.com/docs/8.0.x/HTML/ ... Limits.htm

If you try to create a FLEX table with more than 1600 columns, you will get an error…

Example:

[dbadmin@s18384357 ~]$ head -10 big_flex.sql
create flex table big_flex (
col1 int,
col2 int,
col3 int,
col4 int,
col5 int,
col6 int,
col7 int,
col8 int,
col9 int,


[dbadmin@s18384357 ~]$ tail -10 big_flex.sql
col1592 int,
col1593 int,
col1594 int,
col1595 int,
col1596 int,
col1597 int,
col1598 int,
col1599 int,
col1600 int);

[dbadmin@s18384357 ~]$ vsql -f big_flex.sql
vsql:big_flex.sql:1601: ROLLBACK 2106: A table/projection/view can only have up to 1600 columns -- this create statement has 1601
Jim Knicely

Image

Note: I work for Vertica. My views, opinions, and thoughts expressed here do not represent those of my employer.

Post Reply

Return to “New to Vertica Database Administration”