1、这个函数实现两个数值的相加

create or replace function test( Mat1 INTEGER, Mat2 INTEGER)
  returns integer
  language plpgsql
AS
$$
declare
  count1 integer;
begin
  count1 = (Mat1 + Mat2 );
  return count1;
end;
$$

2、调用方式

SELECT test(1,2)

 

最后修改于 2020-07-28 18:12:25
如果觉得我的文章对你有用,请随意赞赏
扫一扫支付
上一篇