(PostgreSQL)错误:无法打开关系 [英] (PostgreSQL) ERROR: could not open relation

查看:618
本文介绍了(PostgreSQL)错误:无法打开关系的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遇到这个奇怪的错误

Caused by: org.postgresql.util.PSQLException: ERROR: could not open
relation base/17369/1684: No such file or directory

如何从中恢复?
任何想法吗?

How do I recover from it ? Any ideas ?

谢谢

推荐答案

您输了与表1684和数据库17369相关的文件。在目录base / 17369中检查名称为1684的状态文件

You lost file related to table 1684 and database 17369. Check presence file with name 1684 in directory base/17369.

您可以确定它是哪个表:

You can determine which table it is:

1)获取数据库名称:从pg_database中选择*,其中oid = 17369

1) get database name: select * from pg_database where oid=17369

2)获取表名(连接到受影响的数据库): select * from pg_class where oid = 1684

2) get table name (connect to affected database): select * from pg_class where oid=1684

可能没有更多可以做的了。仅从备份还原。

Probably there is not much more you can do. Only restore from backup.

这篇关于(PostgreSQL)错误:无法打开关系的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆