Replace Script with flow designer in ServiceNow| How to create flow designer in ServiceNow | #NOCODE
[Music] in order to subscribe to my channel please click here or click here please share comment and like my videos and channel hello guys welcome to sas with service now in this video i will show you how you can replace a script with flow designer that means if you have achieved a requirement with the help of a script maybe you have written that script in a business rule how exactly you can achieve that requirement without writing a script with the help of flow designer and that's what you can achieve with flow designer so if you remember in one of our practical use case we talked about one scenario in which we created four scrum tasks when a story is created so if you can see the scenario again that when story is created then it should automatically create four different scrum tasks rackets of development testing analysis documentation now these are four different types of scrum tasks now how exactly we achieved this requirement we achieved this requirement with the help of a business rule that is also we wrote a script in that particular business rule so let me take you to my personal developer instance so this is my personal developer instance before i create a flow designer a flow inflow designer i will show you that script and that functionality again so that you understand how exactly we are converting into flow and how we are able to achieve same requirement without scripting with the help of flow designer so if i go to agile uh here we have a stories module and if you remember we created these records and if i and if you have not seen that particular video i will paste the link of that particular video in the description so you will find that link as well if you have not seen that video so i will quickly go to business rules which we created so here is the list of business rules now this was the business rule which we created so you can see the name of this business rule is create scrum tasks and if i show you the condition was when exactly it was supposed to run so whenever record is being inserted in story table new racket then it should trigger this script and this script is basically creating scrum tasks for different scrum tasks you can see we also basically mentioned the loop as well so that it can create four different scrum tasks now how exactly we can achieve it with the help of flow designer without writing a single script so yes we can do that so what i can do i can just first disable this and i can maybe before disabling it let me show you the functionality first in that case i will go to stories directly and i will click on new i will just do test for scrum task and i will click on save when i will click on save you will see four different scrum tasks will be created at the bottom right here you can see ford scrum tasks are created now what i will do i will disable this business rule so i'm going to business rules again list of business rules and we have this business rule and i'm going to just disable it we will deactivate it so it is deactivated so this particular business tool won't work anymore we will check it before i go to floor designer and we will create another story and i will write here test for test maybe after disabling br and i will click on save let's see if it works so this story is created and if i go little bit bottom here you can see none of the some tasks have been created even if i refresh let me check no nothing nothing have been created so what i will do now i will try to achieve same functionality without scripting in flow designer and we will create the flow now in order to get access to the flow you have to type here flow and you will get this application flow designer and here is the designer if you will click this module it will open up in a new tab and that tab is this one so this is the screen of flow designer where you can create new or different flows as per your requirement so what i will do i will click here new and i will click on flow now and here i will give it a name as create scrum tasks that is the name i am giving to this flow and i am clicking on submit now this will create the flow like we do in workflow this will create the flow now here as of now it's not completed yet because we have to add the trigger condition and we also need to add action what action you want to take once that triggering condition is being met so for that what we will do as part of this flow designer you will start with trigger now when exactly you want to trigger this flow and that is if i take you to the business rule and i will open this it is deactivated but you can still the you can still see the configurations we have if i click on when to run now it is basically running when you are inserting a record in this table so we will do the same thing over here so i will click on this uh trigger and i will do create it so we will basically trigger it when that record will be created and we will select the table here and that table would be story table that's what we want so i will select story table you don't have to do anything you can just click on done that's it that means this trigger condition is created now we will create action now what actions we have to create we have to create actions so that i can create those four scrum task records associated with the same story which is being created so what i can do now i will create those scum tasks so i will click on action we will click on create task and i will select the table here i will select scrum task okay that's a table where we have to create the racket now i will select the short description first because we have we set some value so i will show you the business rule if you remember here if you will see we are setting short description we are setting type and we are also setting story because that's how it will relate to the same story so we have to populate all those three rackets so we will start with so we will do analysis coding documentation testing so i will start with short description analysis i will add another value that will be type i select type here and we will select analysis and the third field we will do story now what story you can select here i don't have any story number or a story society so the best feature in flow is you can already reference here it's kind of a data picker so you can see we are creating this basically racket so you can select here record created so it will automatically pick the same record and tag it to the scrim task automatically so i will click on done now i will create another task now before i create another task you can give on annotations here and that's a great feature so that you can identify what this particular task or action is doing so i can do create analysis task i can press enter now i will create another record so i will go to create record i will select the table now you can see i'm not writing a single code over here in flow designer you can still definitely write a code as well there are some features which you can utilize but maximum functionality you can achieve without scripting so i will do here short description and here i will do so this time we will select coding so i will select coding add value here i will select another field that is type i can just select coding and i can select story same thing data picker same record this one i will click on done and i can give annotation as well create coding task press enter i will create another one create record and i will select here scrum task i will select value shot description and this time short description can be documentation and the last one is testing so i have documentation i can put here type type as documentation and then i will select story so that it can tag the story i will select here record created story record same society which will be created over here at the top this in this basically trigger and i can click on done and i can give annotation as create documentation task press enter and the last one would be because we have to create four records and the last one would be i will select short description and this one is testing that's the last one so i will select type now i will select testing and here i will select story again and we'll select that same society which will be created over here when flow will run and i can click on done and i will give the annotation as well and annotation is create and we can give testing task press enter uh let me check we have some tasks everything should be good if i click here everything should be good if i click here it is also good all good now you can see you can see some difference here it says create task and here it says create scrum task record right that's what we have basically it selects the table we have um ideally it should take so that that's fine it will still create all these four records uh basically automatically what we are achieving with the help of scripting so what i will do now i will click on save so i will save this new flow which we have created and i will click on activate now before i activate i will just quickly tell you a really great feature of flow designer that you can also run the test so if i click on test it will it will give you opportunity to test for any particular racket and you can click on run so after selecting the record you can click on run as well so as of now because this is not our real environment so i will just this is just my demo environment so i will just click on activate and we can test it live so i will click on ok so this is activated and now what i will do i will go to my story record and try to create a new story and we will see whether we are able to create these four scum tasks or not so i will go here and let me just quickly check one thing the difference we have here you can see we are doing create task and we are selecting create task here but here we are selecting a racket that's a difference guys so it's totally up to you if you will select scrum basically create task it will create the task because it is basically it will make sure that you can also basically put if you want to uh basically maybe check colace in that case you can select it so as of now i'm not changing it but if you want you can also change that but i'm not changing for now because it will still work both will still work so i am going to here and because while creating it i didn't realize that i selected for two records i selected create task record and for two records i selected just single uh create record so i will go to agile now now our business rule is deactivated so it was not working we saw it i will go to stories and this time i will create a new story so i will click here create task after flow and i will click on save once you will save that and if you will go bottom here you can see nothing is created do you think it is really not created so answer is no because floor designer takes a little bit more time than your business rule i can tell you maybe it's kind of a loophole but anyhow it is not ruining your feature you are still able to create it if i refresh it you can see here all the tasks are created similarly what we were able to achieve with the help of scripting and business rule so if you are targeting or maybe you're not aware of scripting in service now you have not learned it you can still achieve lot of requirement in service now without scripting so that's how you can convert any script you want to write but you don't know how to write that script but you can still achieve that requirement with the help of flow designer so float the designer it's definitely a powerful feature of service now however i showed you one of the loophole that it is pretty much slow not i think not fast as as fast what we have in what we achieve from business rule but you're still able to achieve the automation and it is able to create all these four rackets maybe it took maybe more than i would say three seconds but it didn't create right away but it created maybe after two three seconds but overall you are able to achieve uh the goal achieve the requirements if you will get this kind of requirement from your customers or clients you can directly go to a floor designer and create the flow without writing a single script in your system so i hope you liked this particular video so please like this video comment on this video if you have any feedback if you have any question or if you want to learn any other topic please subscribe to my channel and please share my channel and videos as well thank you have a great day
https://www.youtube.com/watch?v=w4IsSJ9zOX0