ビジネスルールのアクションのフィールド値で変数を選択する方法があれば教えてください

shirakazu
Tera Expert

私は要求アイテムが作成or更新される際、ビジネスルールを利用して変数の値を変更したいと考えています。

その際に、アクションのフィールドを利用して更新したい考えておりますが、アクションのフィールド値には変数が表示されません。変数を値を更新する場合はスクリプトを利用しないと更新はできないのでしょうか?
実行タイミングのフィルター条件では変数は選択できるようでした。

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

@shirakazu 

you can't select variables from the Actions tab, you need to use script only for that

in After insert business rule script syntax is this

current.variables.variableName = 'your value';

current.setWorkflow(false);

current.update();

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

@shirakazu 

you can't select variables from the Actions tab, you need to use script only for that

in After insert business rule script syntax is this

current.variables.variableName = 'your value';

current.setWorkflow(false);

current.update();

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

shirakazu
Tera Expert

@Ankur Bawiskar 
Thank you gor reply

I understood that I cannot select variables from the action.