I am not able to figure out the error in flow designer

mit2324
Kilo Expert

Hi all,

I am working on creating Flow Designer for Inbound Email and the target table is the custom table "Alert Record" which is in custom application scope. But I am getting error while creating a record in the table, but not able to get what's the error.

find_real_file.png

I am getting error in the Create Record part. It's working fine when I use the test option in flow designer, but when I send the email it's showing error in the execution details. Could anyone suggest how to debug the flow or fix the error.

find_real_file.png

find_real_file.png

Regards,

Mithun

1 ACCEPTED SOLUTION

mit2324
Kilo Expert

Hi all,

I was trying to Run As - User who initiates Session, and the user didn't have the access/role to create the record. Once the user was given the role it's working as expected.

Note: 

When a flow runs as a user, the user needs permissions to run the actions executed by the flow. For example, if a user initiates a flow that creates a record, but the user does not have permissions to create the record, the flow stops execution with an error.

Flows that run as the user who initiates the session are safer because they do not execute with the elevated privileges of the System User.

If a flow needs to run with elevated privileges, a developer can set the Run As flow property to System User.

 

Thank you for all your responses.

Regards,

Mithun K R

View solution in original post

15 REPLIES 15

Hi Mithun,

Yes that's correct ideally you should allow flow to run in the session who initiated it

Reason being the corresponding steps in flow should be evaluated as per the user's session. So you should carefully select the Test User

Also you would require to ensure the flow execute properly

That being said you can set it System User based on certain scenarios

https://developer.servicenow.com/dev.do#!/guide/orlando/now-platform/glossary/developer-glossary

If my answer solved your issue, please mark my answer as āœ… Correct & šŸ‘Helpful based on the Impact.

Regards
Ankur

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