2016-10-27 13:53:58 +07:00
|
|
|
{
|
|
|
|
"name": "string_to_array",
|
|
|
|
"type": "function",
|
2020-07-02 01:46:48 +01:00
|
|
|
"groups": ["Arrays"],
|
2016-10-27 13:53:58 +07:00
|
|
|
"description": "Splits string into an array using supplied delimiter and optional string for empty values.",
|
|
|
|
"arguments": [
|
|
|
|
{"arg":"string", "description":"the input string"},
|
|
|
|
{"arg":"delimiter","optional":true,"default":"','","description":"the string delimiter used to split the input string"},
|
2016-11-05 11:21:13 +07:00
|
|
|
{"arg":"empty_value","optional":true,"default":"''","description":"the optional string to use as replacement for empty (zero length) matches"}],
|
2022-01-12 10:26:38 -05:00
|
|
|
"examples": [{ "expression":"string_to_array('1,2,3',',')", "returns":"[ '1', '2', '3' ]"},
|
2019-12-03 14:48:59 +01:00
|
|
|
{ "expression":"string_to_array('1,,3',',','0')", "returns":"[ '1', '0', '3' ]"}],
|
2022-01-12 10:26:38 -05:00
|
|
|
"tags": [ "split", "convert", "separate", "delimiter", "divides" ]
|
2016-10-27 13:53:58 +07:00
|
|
|
}
|