Error: 'invalid byte sequence for encoding 'UTF8': 0x00' when accessing Triggers or Webhooks
如果你在尝试通过仪表板访问项目的触发器或网络钩子时遇到错误:'invalid byte sequence for encoding "UTF8": 0x00',这表明standard_conforming_strings数据库设置目前是off。
🌐 If you encounter the error: 'invalid byte sequence for encoding "UTF8": 0x00' when attempting to access your project's Triggers or Webhooks via the dashboard, it indicates that the standard_conforming_strings database setting is currently off.
当这个设置为 off 时,可能会导致 Postgres 对某些字符序列的解释出现问题,从而在期望 UTF8 合规字符串的仪表板查询中产生错误。
🌐 This setting, when off, can cause issues with how certain character sequences are interpreted by Postgres, leading to errors in dashboard queries that expect UTF8-compliant strings.
为了解决这个问题:
🌐 To resolve this issue:
-
使用仪表板中的SQL 编辑器或像
psql这样的客户端连接到你的数据库实例。 -
执行以下 SQL 命令:
1ALTER DATABASE postgres SET standard_conforming_strings = on; -
请给这个设置几分钟时间生效,因为现有的连接池可能会保留之前的配置。如果过一段时间错误仍然存在,可能需要重启数据库。