I have to convert some JS functions to snowflake udfs. It works successfully with hardcoded sample data but I can't make it accept user input as arguments. I know the UDF's create statement is supposed to take the input but I cannot make it work.
CREATE OR REPLACE FUNCTION findAndReplace()
RETURNS variant
LANGUAGE JAVASCRIPT
AS
$$
return execute(map,value);
$$
;
select findAndReplace();
Thanks for the help.