Record Triggered Flow: {!$Record.Id} not found - Answers - Salesforce Trailblazer Community
Trailblazer Community
Ask Search:
David BaumannDavid Baumann 

Record Triggered Flow: {!$Record.Id} not found

To be honest, I am a bit confused and it seems that I miss something obvious..

Up to now, when I wanted to trigger a flow which references the current record, I creates a variable {!recordId} and passes it along within my flow. Now I thought it would be possible to use {!$Record.Id} in the first Get Records Element to achieve the same result wihthin an after save flow but I get the error "No records found".
Where is my mistake?

Regards,
David
Best Answer chosen by David Baumann
Vishal NegandhiVishal Negandhi

Hi David, 

I was having a look at this article

https://admin.salesforce.com/blog/2020/learn-moar-about-lightning-flow-goodies-coming-in-summer-20

And it says that we still need recordId variable but instead of it being a text, it can now be a "Record" variable so you can access all fields. 

I hope this clarifies.

Best,

Vishal

All Answers

Vishal NegandhiVishal Negandhi

Hi David, 

Why would you not use the same variable "{!recordId}" in your Get records element?

Ramaseshu PallavajjulaRamaseshu Pallavajjula
Hi David,
The variable should be declared as recordId not as Record.Id and use it as mentioned below:

User-added image



 
David BaumannDavid Baumann
Hi Vishai, Hi Ramaseshu,
thanks for your swift replies! I know how to handle the {!recordId} variable (thats the way all my flows are build) but for some reason I thought that I have read somewhere that - with the lasted flow releases - I do not need to declare {!recordId} anymore to reference the current record... it seems to me that I have definitely misunderstood something here...?
Vishal NegandhiVishal Negandhi

Hi David, 

I was having a look at this article

https://admin.salesforce.com/blog/2020/learn-moar-about-lightning-flow-goodies-coming-in-summer-20

And it says that we still need recordId variable but instead of it being a text, it can now be a "Record" variable so you can access all fields. 

I hope this clarifies.

Best,

Vishal

This was selected as the best answer