
sqltemplates.insertFolderFunc.sql Maven / Gradle / Ivy
--
-- Copyright (C) 2011-2015 Incapture Technologies LLC
--
-- This is an autogenerated license statement. When copyright notices appear below
-- this one that copyright supercedes this statement.
--
-- Unless required by applicable law or agreed to in writing, software is distributed
-- on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
-- or implied.
--
-- Unless explicit permission obtained in writing this software cannot be distributed.
--
CREATE OR REPLACE FUNCTION public.rap_insertF_%1$s(f character, t character, nature text)
RETURNS folderType
LANGUAGE plpgsql
AS $function$
DECLARE
version folderType;
BEGIN
SELECT INTO version N FROM %2$s WHERE ID=f AND SUB=t;
IF NOT FOUND THEN
INSERT INTO %2$s VALUES(f, t, nature::folderType);
END IF;
return version;
END;$function$
© 2015 - 2025 Weber Informatics LLC | Privacy Policy