====== pears.ValidationResults ======
Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace.
===== Original SQL =====
create function "pears"."ValidationResults"()
returns long varchar
begin
declare "ValidationText" long varchar;
declare "LoopCounter" integer;
declare "NewLine" char(2);
set "NewLine" = "char"(13)+"char"(10);
set "LoopCounter" = 0;
for "GetText" as "TextCursor" dynamic scroll cursor for call "sa_validate"() do
if "LoopCounter" > 0 then
set "ValidationText" = "ValidationText" || "NewLine"
end if;
set "ValidationText" = "ValidationText" || "Messages";
set "LoopCounter" = "LoopCounter"+1 end for;
return("ValidationText")
end