支持不使用$$语法

最近更新时间: 2024-06-12 15:06:00

  • 使用$$符号。

     postgres=# create or replace procedure p_dollor() is
     $$
     begin
         raise notice '使用美元符号';
     end;
     $$
     /
     CREATE PROCEDURE
  • 不使用$$符号。

     postgres=# create or replace procedure p_dollor() is
     begin
         raise notice '不使用美元符号';
     end;
     /
     CREATE PROCEDURE
     postgres=# call p_dollor();
     NOTICE:  不使用美元符号
     CALL
     postgres=#