Show pageOld revisionsBacklinksExport to PDFFold/unfold allBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== pears.getline ====== <WRAP center round info> Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace. </WRAP> ===== Original SQL ===== <code sql> COMMENT TO PRESERVE FORMAT ON PROCEDURE "pears"."getline" IS {create function getline /* Application Maintained Function / Procedure - DO NOT EDIT*/ (in s1 long varchar,in ln1 smallint) returns long varchar begin declare i smallint; declare ln smallint; declare s long varchar; set ln=ln1; set s=s1; loop1: loop set ln=ln-1; if ln <= 0 then leave loop1 end if; set i=charindex("char"(13),s); if i > 0 and length(s) > i+1 then set s=stuff(s,1,i+1,'') else set s='' end if end loop loop1; set i=charindex("char"(13),s); if i > 0 then set s="left"(s,i-1) end if; return(s) end } </code> database/procedures/pears_getline.txt Last modified: 2026/08/07 19:24by 127.0.0.1