diff --git a/RESTAPI/Functions/GENERATE_DBML3.sql b/RESTAPI/Functions/GENERATE_DBML3.sql
index a548399..09a650a 100644
--- a/RESTAPI/Functions/GENERATE_DBML3.sql
+++ b/RESTAPI/Functions/GENERATE_DBML3.sql
@@ -1 +1,104 @@
-âÅã@×ÁãÈ@\ÓÉÂÓ@^@
%
%ÃÙÅÁãÅ@ÖÙ@ÙÅ×ÓÁÃÅ@ÆäÕÃãÉÖÕ@ÙÅâãÁ×ÉKÇÅÕÅÙÁãÅmÄÂÔÓó@M@
%ÉÕÁ××åÅÙ@åÁÙÃÈÁÙMñð]@k@
%ÉÕÁ××ÕÁÔÅ@åÁÙÃÈÁÙMñòø]@]@
%ÙÅãäÙÕâ@ÃÓÖÂMòñô÷ôøóöô÷]@@@
%ÓÁÕÇäÁÇÅ@âØÓ@
%â×ÅÃÉÆÉÃ@ÙÅâãÁ×ÉKÇÅÕÅÙÁãÅmÄÂÔÓó@
%ÕÖã@ÄÅãÅÙÔÉÕÉâãÉÃ@
%ÙÅÁÄâ@âØÓ@ÄÁãÁ@
%ÃÁÓÓÅÄ@ÖÕ@ÕäÓÓ@ÉÕ×äã@
%âÅã@Ö×ãÉÖÕ@@ÁÓæÂÓÒ@~@\ÁÓÓÙÅÁÄ@k@
%ÁÓæÃ×èÄãÁ@~@\Ö×ãÉÔÉéÅ@k@
%ÃÖÔÔÉã@~@\ÕÖÕÅ@k@
%ÄÂÇåÉÅæ@~@\âÖäÙÃÅ@k@
%ÄÅÃÙÅâäÓã@~@Móñk@óñk@ðð]@k@
%ÄèÕÄÆãÃÖÓ@~@\ÕÖ@k@
%ÄèÕäâÙ×ÙÆ@~@\ÖæÕÅÙ@k@
%âÙãâÅØ@~@\ÈÅç@@@
%ÂÅÇÉÕ@
%ÄÅÃÓÁÙÅ@åmÙÅâäÓã@ÃÓÖÂ@M@ò@Ç@]@^@
%âÅÓÅÃã@çÔÓâÅÙÉÁÓÉéÅ@M@ÃÖÕãÅÕã@çÔÓÅÓÅÔÅÕã@M@ÕÁÔÅ@„‚”“@k@çÔÓÁããÙÉÂäãÅâ@M@
%}a¥ñ}@Áâ@™…¢£ä™‰×�£ˆã…”—“�£…@k@}ñKð}@Áâ@¥…™¢‰–•@]@k@çÔÓÁÇÇ@M@
%çÔÓÅÓÅÔÅÕã@M@ÕÁÔÅ@—™–‡™�”@k@çÔÓÁããÙÉÂäãÅâ@M@}}@Áâ@…™™–™”…¢¢�‡…@k@
%}\ÕÖÕÅ}@Áâ@ˆ££—ˆ…�„…™¢@k@}õðð}@Áâ@ˆ££—¢£�£¤¢–•†�‰“¤™…@k@ÃÈÁÙ@M@
%Å@K@âäÃÃÅââmÃÖÄÅ@]@Áâ@ˆ££—¢£�£¤¢–•¢¤ƒƒ…¢¢@k@}‡…£}@OO@
%äÃÁâÅ@M@âäÂâãÙ@M@â@K@Á××ÆäÕÃ@k@ñ@k@ñ@]@]@OO@âäÂâãÙ@M@â@K@Á××ÆäÕÃ@k@ò@]@OO@
%}É•—¤£}@Áâ@‰•—¤£æ™�——…™É„…•£‰†‰…™@k@}‡…£}@OO@
%äÃÁâÅ@M@âäÂâãÙ@M@â@K@Á××ÆäÕÃ@k@ñ@k@ñ@]@]@OO@âäÂâãÙ@M@â@K@Á××ÆäÕÃ@k@ò@]@Áâ@
%•�”…@k@}‡…£}@OO@äÃÁâÅ@M@âäÂâãÙ@M@â@K@Á××ÆäÕÃ@k@ñ@k@ñ@]@]@OO@
%âäÂâãÙ@M@â@K@Á××ÆäÕÃ@k@ò@]@OO@}Ù…¢¤“£}@Áâ@–¤£—¤£æ™�——…™É„…•£‰†‰…™@k@
%}”…„‰�`™…¢–¤™ƒ…}@Áâ@˜¤…™¨£¨—…@k@Å@K@ÃÖÕâäÔÅâ@Áâ@™…¢£Ã–•¢¤”…¢@k@
%Å@K@Èãã×mÔÅãÈÖÄ@Áâ@™…¢£È££—Ù…˜¤…¢£Ô…£ˆ–„@k@Å@K@×ÙÖÄäÃÅâ@Áâ@
%™…¢£×™–„¤ƒ…¢@k@Å@K@×ÁãÈmãÅÔ×ÓÁãÅ@Áâ@™…¢£ä™‰×�£ˆã…”—“�£…@k@}\ÅÙÙÖÙâ}@
%Áâ@™…£¤™•¢˜“¢£�£…@k@}£™¤…}@Áâ@£™…�£¦�™•‰•‡�¢…™™–™@k@}\ãÙÁÉÓÉÕÇ}@
%Áâ@£™‰””–„…@k@}†�“¢…}@Áâ@¦™�—É•—¤£×�™�”¢@k@}£™¤…}@Áâ@
%¦™�—Ö¤£—¤£×�™�”@]@k@
%a\@L¢˜“@KKKn@¦‰£ˆ@¢£�£…”…•£@‚¤‰“£@‰•“‰•…@\a@
%çÔÓÅÓÅÔÅÕã@M@ÕÁÔÅ@¢˜“@k@çÔÓÁããÙÉÂäãÅâ@M@
%a\@ÓÉâãÁÇÇ@™…£¤™•…„@�¢@ÃÓÖÂ@£–@�¥–‰„@óò’@¢…“…ƒ£`“‰¢£@“‰”‰£@\a@
%}å�“¤…¢@Ù…¢£�—‰KÅ§…ƒ¤£…mâ˜“M}}}@OO@â@K@Á××åÅÙ@OO@}}}k}}}@OO@â@K@Á××ÕÁÔÅ@
%OO@}}}k}}}@OO@â@K@Á××ÆäÕÃ@OO@}}}k@Ã�¢£MÑ¢–•mÖ‚‘…ƒ£M}@OO@
%ÃÖÁÓÅâÃÅ@M@
%M@
%âÅÓÅÃã@ÃÁâã@M@
%ÓÉâãÁÇÇ@M@
%}}}}@OO@×@K@Á×××ÁÙÁÔ@OO@}}}z}@OO@}o}@k@}k@}@]@
%æÉãÈÉÕ@ÇÙÖä×@M@ÖÙÄÅÙ@Âè@×@K@×ÁÙÁÔ×Öâ@]@Áâ@ÃÓÖÂ@M@öô@Ò@]@
%ÃÃâÉÄ@ñòðø@]@
%ÆÙÖÔ@ãÁÂÓÅ@M@
%ÙÅâãÁ×É@K@ÇÅãm×ÁÙÁÔm×ÓÁÃÅÈÖÓÄÅÙâó@M@
%â@K@Á××åÅÙ@k@â@K@Á××ÕÁÔÅ@k@â@K@Á××ÆäÕÃ@]@
%]@Áâ@×@]@k@ÃÁâã@M@}}@Áâ@ÃÓÖÂ@M@ñ@Ò@]@]@]@OO@
%}@]@Á¢@å�™ƒˆ�™Mñðòôð]@ÃÃâÉÄ@ó÷]]}@Áâ@¢£�£…”…•£@]@k@
%a\@L„�£�@KKKan@…“…”…•£¢@‚¤‰“£@¥‰�@ƒ–™™…“�£…„@çÔÓÁÇÇ@\a@
%çÔÓ×ÁÙâÅ@M@ÄÖÃäÔÅÕã@çÔÓâÅÙÉÁÓÉéÅ@M@ÃÖÕãÅÕã@çÔÓÁÇÇ@M@çÔÓÅÓÅÔÅÕã@M@ÕÁÔÅ@
%„�£�@k@çÔÓÁããÙÉÂäãÅâ@M@ÃÖÁÓÅâÃÅ@M@×@K@ÃÃâÉÄ@k@ñòðø@]@Áâ@ƒƒ¢‰„@k@
%×@K@Á×××ÁÙÁÔ@Áâ@•�”…@k@
%ÃÁâÅ@
%æÈÅÕ@×@K@ÉâmÙÅØäÉÙÅÄ@~@ñ@ãÈÅÕ@}†�“¢…}@
%ÅÓâÅ@}£™¤…}@
%ÅÕÄ@Áâ@•¤““�‚“…@k@
%ÃÁâÅ@
%æÈÅÕ@×@K@ãè×ÅÕÁÔÅ@~@}ÃÓÖÂ}@ãÈÅÕ@òñô÷ôøóöô÷@
%æÈÅÕ@
%×@K@ãè×ÅÕÁÔÅ@ÉÕ@M@}åÁÙÃÈÁÙ}@k@}ÃÈÁÙ}@]@
%ãÈÅÕ@ÃÖÁÓÅâÃÅ@M@×@K@ÓÅÕÇãÈ@k@òõö@]@
%æÈÅÕ@
%×@K@ãè×ÅÕÁÔÅ@ÉÕ@M@}ÄÅÃÉÔÁÓ}@k@}ÕäÔÅÙÉÃ}@]@
%ãÈÅÕ@ÃÖÁÓÅâÃÅ@M@×@K@ÓÅÕÇãÈ@k@óñ@]@
%
\ No newline at end of file
+SET PATH *LIBL ; 
+
+CREATE OR REPLACE FUNCTION RESTAPI.GENERATE_DBML3 ( 
+	INAPPVER VARCHAR(10) , 
+	INAPPNAME VARCHAR(128) ) 
+	RETURNS CLOB(2147483647)   
+	LANGUAGE SQL 
+	SPECIFIC RESTAPI.GENERATE_DBML3 
+	NOT DETERMINISTIC 
+	READS SQL DATA 
+	CALLED ON NULL INPUT 
+	SET OPTION  ALWBLK = *ALLREAD , 
+	ALWCPYDTA = *OPTIMIZE , 
+	COMMIT = *NONE , 
+	DBGVIEW = *SOURCE , 
+	DECRESULT = (31, 31, 00) , 
+	DYNDFTCOL = *NO , 
+	DYNUSRPRF = *OWNER , 
+	SRTSEQ = *HEX   
+	BEGIN 
+DECLARE V_RESULT CLOB ( 2 G ) ; 
+SELECT XMLSERIALIZE ( CONTENT XMLELEMENT ( NAME "dbml" , XMLATTRIBUTES ( 
+'/v1' AS "restUriPathTemplate" , '1.0' AS "version" ) , XMLAGG ( 
+XMLELEMENT ( NAME "program" , XMLATTRIBUTES ( '' AS "errormessage" , 
+'*NONE' AS "httpheaders" , '500' AS "httpstatusonfailure" , CHAR ( 
+E . SUCCESS_CODE ) AS "httpstatusonsuccess" , 'get' || 
+UCASE ( SUBSTR ( S . APPFUNC , 1 , 1 ) ) || SUBSTR ( S . APPFUNC , 2 ) || 
+'Input' AS "inputWrapperIdentifier" , 'get' || 
+UCASE ( SUBSTR ( S . APPFUNC , 1 , 1 ) ) || SUBSTR ( S . APPFUNC , 2 ) AS 
+"name" , 'get' || UCASE ( SUBSTR ( S . APPFUNC , 1 , 1 ) ) || 
+SUBSTR ( S . APPFUNC , 2 ) || 'Result' AS "outputWrapperIdentifier" , 
+'media-resource' AS "querytype" , E . CONSUMES AS "restConsumes" , 
+E . HTTP_METHOD AS "restHttpRequestMethod" , E . PRODUCES AS 
+"restProduces" , E . PATH_TEMPLATE AS "restUriPathTemplate" , '*ERRORS' 
+AS "returnsqlstate" , 'true' AS "treatwarningaserror" , '*TRAILING' 
+AS "trimmode" , 'false' AS "wrapInputParams" , 'true' AS 
+"wrapOutputParam" ) , 
+/* <sql ...> with statement built inline */ 
+XMLELEMENT ( NAME "sql" , XMLATTRIBUTES ( 
+/* LISTAGG returned as CLOB to avoid 32k select-list limit */ 
+'Values Restapi.Execute_Sql(''' || S . APPVER || ''',''' || S . APPNAME 
+|| ''',''' || S . APPFUNC || ''', Cast(Json_Object(' || 
+COALESCE ( 
+( 
+SELECT CAST ( 
+LISTAGG ( 
+'''' || P . APPPARAM || ''':' || '?' , ', ' ) 
+WITHIN GROUP ( ORDER BY P . PARAMPOS ) AS CLOB ( 64 K ) 
+CCSID 1208 ) 
+FROM TABLE ( 
+RESTAPI . GET_PARAM_PLACEHOLDERS3 ( 
+S . APPVER , S . APPNAME , S . APPFUNC ) 
+) AS P ) , CAST ( '' AS CLOB ( 1 K ) ) ) || 
+' ) As Varchar(10240) CCSID 37))' AS "statement" ) , 
+/* <data .../> elements built via correlated XMLAGG */ 
+XMLPARSE ( DOCUMENT XMLSERIALIZE ( CONTENT XMLAGG ( XMLELEMENT ( NAME 
+"data" , XMLATTRIBUTES ( COALESCE ( P . CCSID , 1208 ) AS "ccsid" , 
+P . APPPARAM AS "name" , 
+CASE 
+WHEN P . IS_REQUIRED = 1 THEN 'false' 
+ELSE 'true' 
+END AS "nullable" , 
+CASE 
+WHEN P . TYPENAME = 'CLOB' THEN 2147483647 
+WHEN 
+P . TYPENAME IN ( 'VARCHAR' , 'CHAR' ) 
+THEN COALESCE ( P . LENGTH , 256 ) 
+WHEN 
+P . TYPENAME IN ( 'DECIMAL' , 'NUMERIC' ) 
+THEN COALESCE ( P . LENGTH , 31 ) 
+WHEN 
+P . TYPENAME IN ( 'INTEGER' , 'INT' , 'SMALLINT' , 'BIGINT' ) 
+THEN 10 
+ELSE 256 
+END AS "precision" , 
+CASE 
+WHEN P . LOCATION = 'PATH' THEN P . RESTNAME 
+END AS "restInPathParam" , 
+CASE 
+WHEN P . LOCATION = 'QUERY' THEN P . RESTNAME 
+END AS "restInQueryParam" , 
+CASE 
+WHEN P . LOCATION = 'FORM' THEN P . RESTNAME 
+END AS "restInFormParam" , P . TYPENAME AS "type" , 'input' AS "usage" 
+) ) ORDER BY P . PARAMPOS ) AS CLOB ( 1 M ) CCSID 1208 ) ) ) ) ORDER BY 
+S . APPFUNC ) ) AS CLOB ( 2 G ) ) 
+INTO V_RESULT 
+FROM 
+RESTAPI . SQLSTMTS S 
+JOIN RESTAPI . ENDPOINTS E 
+ON ( E . APPVER , E . APPNAME , E . APPFUNC ) = ( S . APPVER , 
+S . APPNAME , S . APPFUNC ) 
+WHERE ( S . APPVER , S . APPNAME ) = ( INAPPVER , INAPPNAME ) ; 
+RETURN V_RESULT ; 
+END  ; 
+
+GRANT ALTER , EXECUTE   
+ON SPECIFIC FUNCTION RESTAPI.GENERATE_DBML3 
+TO AMAPICS WITH GRANT OPTION ; 
+
+GRANT EXECUTE   
+ON SPECIFIC FUNCTION RESTAPI.GENERATE_DBML3 
+TO PUBLIC ; 
+
