云数据库 GAUSSDB-BEGIN:语法格式

时间:2024-11-02 18:46:42

语法格式

  • 开启匿名块。
    1
    2
    3
    4
    5
    [DECLARE [declare_statements]] 
    BEGIN
    execution_statements  
    END;
    /
    
  • 开启事务。
    1
    2
    3
    4
    5
    6
    7
    BEGIN [ WORK | TRANSACTION ]
      [ 
        { 
           ISOLATION LEVEL { READ COMMITTED | SERIALIZABLE | REPEATABLE READ }
           | { READ WRITE | READ ONLY }
          } [, ...] 
      ];
    
support.huaweicloud.com/distributed-devg-v3-gaussdb/gaussdb-12-0498.html