diff --git a/contrib/gms_lob/expected/gms_lob.out b/contrib/gms_lob/expected/gms_lob.out index c35921e54bae7185e90c2c95bc1d8983c2473a58..324e3b9164ebee3895d60f6628cba949b90c2bef 100644 --- a/contrib/gms_lob/expected/gms_lob.out +++ b/contrib/gms_lob/expected/gms_lob.out @@ -166,9 +166,14 @@ END; $$LANGUAGE plpgsql; select func_clob(); clob2: +clob2: +clob1:clob test clob1:clob test clob2:clob test +clob2:clob test clob3:中文clobobject测试 +clob3:中文clobobject测试 +clob3:中文clobobject测clob test clob3:中文clobobject测clob test func_clob ----------- @@ -177,10 +182,16 @@ clob3:中文clobobject测clob test select func_blob(); blob1:626C6F62 +blob1:626C6F62 +blob2: blob2: blob1:626C6F62 +blob1:626C6F62 blob2:626C6F62 +blob2:626C6F62 +blob3:E4B8ADE69687626C6F626F626A656374E6B58BE8AF95 blob3:E4B8ADE69687626C6F626F626A656374E6B58BE8AF95 +blob3:E4B8ADE69687626C6F626F626A656374E6B58BE8AF626C6F62 blob3:E4B8ADE69687626C6F626F626A656374E6B58BE8AF626C6F62 func_blob ----------- @@ -260,6 +271,8 @@ BEGIN END; / isopen: 1 +isopen: 1 +isopen: 0 isopen: 0 -----------freetemporary函数----------- DECLARE @@ -275,6 +288,8 @@ BEGIN END; / Chinese中国人 字符长度:10 +Chinese中国人 字符长度:10 + 释放后再输出: 释放后再输出: drop table tbl_testlob; drop function func_clob; @@ -307,6 +322,7 @@ gms_output.put_line(r1::text); end; / 616263 +616263 -- float declare b1 blob :=cast_to_raw('ABCDEFGH'); @@ -321,6 +337,7 @@ gms_output.put_line(r1::text); end; / 616263 +616263 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount float :=3.8; @@ -334,6 +351,7 @@ gms_output.put_line(r1::text); end; / 62634546 +62634546 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount float :=3.8; @@ -345,6 +363,7 @@ gms_output.put_line(r1::text); end; / 43444546 +43444546 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount INTEGER :=3; @@ -358,6 +377,7 @@ gms_output.put_line(r1::text); end; / 616263 +616263 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount INTEGER :=3; @@ -455,6 +475,7 @@ gms_output.put_line(r1::text); end; / 3131 +3131 --gms_lob.gms_lob_read_clob declare c1 clob :='abcdefgh'; @@ -467,6 +488,7 @@ gms_output.put_line('clob read: ' || var_buf::text); end; / clob read: abc +clob read: abc declare c1 clob :='abcdefgh'; amount INTEGER :=3; @@ -491,6 +513,7 @@ gms_output.put_line('clob read: ' || var_buf::text); end; / clob read: bcdefgh +clob read: bcdefgh --VALUEERROR --lob为空 declare @@ -588,6 +611,7 @@ gms_output.put_line('clob read: ' || var_buf::text); end; / clob read: 11 +clob read: 11 -----------write函数----------- --gms_lob.gms_lob_write_blob declare @@ -601,6 +625,7 @@ gms_output.put_line(b1::text); end; / 4161626345464748 +4161626345464748 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount INTEGER :=3; @@ -612,6 +637,7 @@ gms_output.put_line(b1::text); end; / 41424344454647616263 +41424344454647616263 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount INTEGER :=3; @@ -623,6 +649,7 @@ gms_output.put_line(b1::text); end; / 41424344454647482020202020202020202020616263 +41424344454647482020202020202020202020616263 --buffer等于destlob declare b1 blob :=cast_to_raw('1234'); @@ -634,6 +661,7 @@ gms_output.put_line(b1::text); end; / 31313234 +31313234 --VALUEERROR --lob为空 declare @@ -674,6 +702,7 @@ gms_output.put_line(b1::text); end; / 4142434461626348 +4142434461626348 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount float :=2.2; -- 2 @@ -685,6 +714,7 @@ gms_output.put_line(b1::text); end; / 4142434461624748 +4142434461624748 declare b1 blob :=cast_to_raw('ABCDEFGH'); amount INTEGER :=4; @@ -775,6 +805,7 @@ gms_output.put_line(c1::text); end; / 22211111 +22211111 -- amount, off_set 不向下取整 declare c1 clob :='11111111'; @@ -800,6 +831,7 @@ gms_output.put_line(c1::text); end; / 12221111 +12221111 declare c1 clob :='11111111'; amount INTEGER :=3; @@ -811,6 +843,7 @@ gms_output.put_line(c1::text); end; / 11111111222 +11111111222 declare c1 clob :='11111111'; amount INTEGER :=3; @@ -822,6 +855,7 @@ gms_output.put_line(c1::text); end; / 11111111 222 +11111111 222 --buffer等于destlob declare c1 clob :='1234'; @@ -833,6 +867,7 @@ gms_output.put_line(c1::text); end; / 1124 +1124 --VALUEERROR --lob为空 declare @@ -936,6 +971,7 @@ gms_output.put_line(b1::text); end; / 3131313131313131323232 +3131313131313131323232 --VALUEERROR --destlob为空 declare @@ -991,6 +1027,7 @@ gms_output.put_line(c1::text); end; / 11111111222 +11111111222 --VALUEERROR --destlob为空 declare @@ -1050,6 +1087,8 @@ gms_output.put_line(c1); end; / 414243313233202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020616263 +414243313233202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020616263 +102 102 declare c1 clob :='ABC123'; @@ -1062,6 +1101,7 @@ gms_output.put_line(c1::text); end; / ABC123 abc +ABC123 abc declare b1 blob :=null; b2 blob :=cast_to_raw('abc'); diff --git a/contrib/gms_sql/expected/gms_sql.out b/contrib/gms_sql/expected/gms_sql.out index a46227b3e939980651aeec463d71978674a71ee0..e080f1c34e5b69cd6b07cf835399590a88137f81 100644 --- a/contrib/gms_sql/expected/gms_sql.out +++ b/contrib/gms_sql/expected/gms_sql.out @@ -479,6 +479,7 @@ NOTICE: mtime,181 NOTICE: createcsn,2 NOTICE: changecsn,2 NOTICE: valid,109 +NOTICE: object_options,2 create table t1(id int, name varchar(20)); insert into t1 select generate_series(1,3), 'abcddd'; create table t2(a int, b date);