I found this error in /var/log/messages yesterday after a cron job
wouldn't complete:
STATEMENT: ALTER TABLE victoria.eodData DROP COLUMN tickDate;
ERROR: tables can have at most 1600 columns
STATEMENT: ALTER TABLE victoria.eodData ADD COLUMN tickerID INTEGER;
ERROR: tables can have at most 1600 columns
...etc...
The columns didn't exist at the time I tried to drop them, and \dt
showed that the table only contained the normal dozen columns. Because I
use the COPY command I remove columns to match the input from an ftp'ed
file, add the columns, continue processing, etc. After dropping and then
re-creating the table the error didn't recur and processing continued.
My question is this: every night the database is vacuumed-full-analyze:
wouldn't that prevent this condition from happening? Or is there some
other regular maintenance I should be running?
I'll be away for the next week but I look forward to reading any insight
on this when I return.
Thanks
Ron
-- running Postgresql 7.4.2 on debian stable