我似乎无法bytea_output改变hex。
我尝试过这个方法:
ALTER DATABASE dbname SET bytea_output TO 'hex';
Run Code Online (Sandbox Code Playgroud)
我尝试编辑 postgresql.conf
bytea_output = 'hex'
Run Code Online (Sandbox Code Playgroud)
并重新启动服务器。
我努力了
SET bytea_output = 'hex'
Run Code Online (Sandbox Code Playgroud)
它适用于每笔交易,但这非常乏味。
然而,每当我在 phpPgAdmin 中浏览我的 bytea 列时,这些列都会被转义输出。
这
SELECT setting FROM pg_settings WHERE name = 'bytea_output'
Run Code Online (Sandbox Code Playgroud)
返回escape。
如何才能bytea_output永久设置为hex?