文字列内の複数の値を 1 つの値に置き換えます
注: この関数はテンプレートでのみ使用でき、レポートでは使用できません。
構文
substitute_all(ATTRIBUTE, "to text", "from text", "from text 2", "from text 3")
パラメータ
属性
: フィード属性(ITEM_TITLE、ITEM_COLOR
、ITEM_BRAND
など)。to text
: 置き換え後の値。from text
: 置き換えたい値。
例
[substitute_all(ITEM_TITLE, "", "®", "Men's ", "Women's ")]
広告のタイトルに含まれている商標記号、Men's とスペース、Women's とスペースを空白に置き換えます。
replace_all 関数は、次のネストされた関数を置き換えます。
[substitute(substitute(substitute(ITEM_TITLE, "®", ""), "Men's ", ""), "Women's ", "")]