Attribute number 10 exceeds number of columns 0

我只是一个虾纸丫 提交于 2019-12-02 04:18:36

Something is broken in your database. Try

VACCUM FULL ANALYZE my_db_log;

Or, more radically, run from the shell on your db server:

vacuumdb --full --analyze my_database

Details in the manual.

The error message indicate breakage in the system catalog pg_attribute or one of the associated indices. Before you do anything else, read about corruption in the Postgres Wiki. Be very careful not to lose valuable data.
Then one other thing to try:

reindexdb --system my_database

If nothing helps, to repair your obviously broken DB, you could try to pg_dumpall the whole cluster, drop the cluster, create a new cluster and restore the backup. Also make sure you find out what broke your db. That does not usually happen (never happened to me, yet). Chances are, you are facing serious hardware problems, in which case you need to act soon ...

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!