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.GetShiftBookedDescription ====== <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> create function "pears"."GetShiftBookedDescription"( /* Application Maintained Function / Procedure - DO NOT EDIT*/ in "vid" char(20),in "pid" char(20),in "edate" date ) returns char(250) begin declare "rv" char(250); for "fetchfor" as "fetchcursor" no scroll cursor for select "string"("GetTempName"("pid"),' (',"tempshiftplan"."description",',',"dateformat"("tempshift"."timefrom",'hh:nn'),'-',"dateformat"("tempshift"."timeto",'hh:nn'),')') as "bdesc" from "tempshift" key join("vacancy","tempshiftplan","person") where "vacancy"."vacancyid" = "vid" and "tempshift"."shiftdate" = "edate" and "tempshift"."personid" = "pid" and "tempshift"."state" not in( 'U','C' ) order by "tempshift"."timefrom" asc,"person"."keyname" asc for read only do if "rv" <> '' then set "rv" = "rv"+"bdesc"+', ' end if; set "rv" = "rv"+"bdesc" end for; return "rv" end </code> database/functions/pears_getshiftbookeddescription.txt Last modified: 2026/08/07 19:24by 127.0.0.1