Whats the backend field name of this source table variable in the notification conditions ?

Anvesha
Tera Contributor

Anvesha_0-1755399266333.png

Need to do anadvanced condition on the source table variable and since its not a reference wantedto dot walk the variable in advanced section. whats the excat backend field value for this condition variable source table ?

2 REPLIES 2

Shashank_Jain
Kilo Sage

 

@Anvesha

 

  • ServiceNow runs your script each time the notification is evaluated.

  • Your script must set answer = true; or answer = false;.

    • true → notification will send

    • false → notification won’t send

  • Write your condition as a small script (answer = true/false;)

  • Use current to access fields (and current.variables.<var_name> for catalog variables)

For example : 

If you want to send only when the caller’s location = "NYC":

 

answer = (current.caller_id.location.name == 'NYC');
 

 

 

 

If this works, please mark it as helpful/accepted — it keeps me motivated and helps others find solutions.
Shashank Jain

AJ-TechTrek
Giga Sage
Giga Sage

Hi @Anvesha ,

 

Why You Can’t Dot-Walk Variables


* Catalog variables (including Source Table) are stored in the sc_item_option_mtom and sc_item_option tables, not directly on the sc_req_item (RITM) or sc_task.
* That means they don’t behave like normal fields and can’t be dot-walked in advanced conditions.

Backend Field Value for "Source Table" Variable
When you create a variable named source_table (or "Source Table"), the backend stores it as:
* variables.source_table


You can use this syntax in:
* Flow Designer condition builder
* Business Rules (via current.variables.source_table)
* Scripted conditions

 

How to Use in Advanced Conditions
1. If using Flow Designer / Advanced condition:
current.variables.source_table == 'incident'
or for multiple values:
['incident', 'change_request'].indexOf(current.variables.source_table) > -1


2. If in Business Rule (Advanced Condition field):
answer = current.variables.source_table == 'incident';


3. If in Report / Filter Condition (not script-based):
Unfortunately, you cannot dot-walk directly in filter conditions

— you’d need to either


* Promote the variable to a field on the table via "Question → Map to Field", OR
* Use a Scripted Filter / BR that pulls current.variables.source_table into a query.

 

Best Practice
If you know this variable will be used often in filters or conditions:
* Map the variable to a field (e.g., u_source_table) on the target table.
* That way, you can dot-walk and filter normally in list views, reports, and conditions.

 

Please appreciate the efforts of community contributors by marking appropriate response as Mark my Answer Helpful or Accept Solution this may help other community users to follow correct solution in future.
 

Thank You
AJ - TechTrek with AJ - ITOM Trainer
LinkedIn:- https://www.linkedin.com/in/ajay-kumar-66a91385/
YouTube:- https://www.youtube.com/@learnitomwithaj
Topmate:- https://topmate.io/aj_techtrekwithaj (Connect for 1-1 Session)
ServiceNow Community MVP 2025