 Hello everyone. I'm Sanjay Gupta. I welcome you on Sanjay Gupta Tech School. In this video, I'm going to demonstrate a scenario on record trigger flow. Let's understand the requirement that I'm going to demonstrate in this video. So I'm going to differentiate dollar record versus dollar record underscore underscore prior global variables. Those are available in the record trigger flow. So these variables are available whenever you trigger your flow on record update. So if you're updating a record, so there are two state of that record. So if I take you to the account record, so here you can see we are having this account record. If I update any value, for example, here in phone, we have this value. If I update this value to some other value. So let's say here instead of seven, I am having eight. Right. So now this is the new value and earlier one was the old value. Right. So if you save this record and the record trigger flow runs so that record trigger flow will be having both the values old value as well as new value. Right. So old value will be available in this dollar record underscore underscore prior and the new value will be available in the dollar record global variable. So now I'm going to demo this with the help of a use case. So we need to create a record trigger flow. So whenever we update a phone on account record. So we need to populate phone fields prior value that is old value, as well as new value in the field of that account record. Okay. So now I'm going to create this flow. So I clicked on record trigger flow. Now here I'm selecting account from here you can choose a record is updated or record is created or updated. So right now we are just focusing on the updates. We are selecting record is updated. Here I'm selecting account phone equals. So you can select is changed through if it is changed, then your record trigger flow will run and we need to update the same record so we can select fast field update and I'm clicking on that. Now here. I'm going to select update record. So update. Okay. So before that, let me just create a resource. So I'm just creating a text template. So it will be having phone new and old value. So here I'm going to create it. So I'm selecting you as plain text. Now, first I'm going to show old value, and then I'm going to show new value. Now here I want the resources. So if you go here and So first we need to show old value. So you can search for record. So here you can see we have these two global variables right record and record underscore underscore prior. So I'm selecting record underscore underscore prior and then phone. Then in next line. I need new values. I'm selecting record dot phone. Both the values will be available. Now I'm clicking on done. Now I need to update the account record. So I'm selecting update record. So update account. Then we need to. In case of fast field update, these options will be disabled. So because by default it is selected use the account record that triggered the flow. So here you can just put description equals and then this text template. Right and done. So this way our record trigger flow is created. And now I can save it. I'm activating it. Now, if I modify this, so here you can see, so let's say instead of 7,000, I'm putting 8888 and I'm clicking on save. So if I go to description, so you hear you can see old value is this and new value is this. So this way, if you update any record. So dollar record will contains the new value of that record updated report and dollar report underscore underscore prior will be having the old value of that updated report. And one more thing, if you if you use any other thing like if I go here and let's say I search for description. For example, okay, it is available. So let's say I am selecting alert node. And here if I search so these record and record prior, both will be available here as well. So in create record get record update record so everywhere you can have these record dollar record and dollar record underscore underscore prior. So this way I hope you understood the difference between dollar record versus dollar record underscore underscore prior. Always remember they will be available in case of update only because in case of create and delete, you have only one state, you don't change the values of that record. So these will be available in case of update.