san*_*dev 3 postgresql plpgsql
我想获取当前的连接架构名称,我发现“show search_path”返回所需的结果,但我需要在查询中使用此结果。
如何在 Postgres 查询中使用“show search_path”?
if not (SELECT EXISTS (SELECT 1 FROM information_schema.tables WHERE
table_name = 'customer' and table_schema = **show search_path** )) then
do something ....
end
Run Code Online (Sandbox Code Playgroud)
我需要使用 table_schema = show search_path
| 归档时间: |
|
| 查看次数: |
5687 次 |
| 最近记录: |