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.RequestEmailStaffNotification ====== <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 procedure "pears"."RequestEmailStaffNotification"( /* Application Maintained Function / Procedure - DO NOT EDIT*/ in "pTopic" char(50),in "pBody" long varchar,in "pHyperLink" char(100),in "pDepartmentID" char(2) default null,in "pDivisionID" char(20) default null ) begin if exists(select "topic" from "EmailStaffNotificationAddress" where "topic" = "ptopic" and("departmentid" = "pdepartmentid" or "departmentid" is null) and("divisionid" = "pdivisionid" or "divisionid" is null)) then insert into "EmailStaffNotification"( "id","topic","body","hyperlink","departmentid","divisionid","requested" ) values ( "uniquekey"('x'),"pTopic","pBody","pHyperLink","pDepartmentID","pDivisionID",current timestamp ) end if end go COMMENT TO PRESERVE FORMAT ON PROCEDURE "pears"."RequestEmailStaffNotification" IS {create procedure RequestEmailStaffNotification /* Application Maintained Function / Procedure - DO NOT EDIT*/ ( in pTopic char(50),in pBody long varchar,in pHyperLink char(100),in pDepartmentID char(2) default null,in pDivisionID char(20) default null ) begin if exists(select topic from EmailStaffNotificationAddress where topic = ptopic and(departmentid = pdepartmentid or departmentid is null) and(divisionid = pdivisionid or divisionid is null)) then insert into EmailStaffNotification( id,topic,body,hyperlink,departmentid,divisionid,requested ) values ( uniquekey('x'),pTopic,pBody,pHyperLink,pDepartmentID,pDivisionID,current timestamp ) end if end } </code> database/procedures/pears_requestemailstaffnotification.txt Last modified: 2026/08/07 19:24by 127.0.0.1