Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
DELIMITER $$
CREATE FUNCTION to_json_array(input_string TEXT, delimiter_char CHAR(1))
RETURNS JSON
BEGIN
RETURN CONCAT("[", TRIM(BOTH delimiter_char FROM input_string), "]");
END$$
DELIMITER ;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment