I want to display the notice from a pgsql function
e.g
Code: Select all
CREATE FUNCTION my_function () RETURNS integer
AS 'DECLARE
mxid integer := 20;
BEGIN
for i in 1..mxid loop
RAISE NOTICE '' I am working on following % '' ,i;
end loop
RETURN
mxid;
END;
'
Code: Select all
try
'execute the function as stored procedure
catch ex as CoreLab.PostgreSql.PgSqlException
label1.text = ex.message
end try
please ignore any errors, if any in postgresql function