Here I am trying to assign value to variable which is null by default. For example as shown below in the example.
Example:
create or replace function fun(va varchar)
returns void as
$$
declare
var1 varchar := null;
begin
var1 := var1 || va;
raise notice '%',var1;
end;
$$
language plpgsql;
Calling Function:
select fun('abc');
Output:
NOTICE: <NULL>
Note: I am unable to get output as abc?