Check if email ID exists in Accounts

Hi all, I want to check if the email ID ($Registrstion/EmailID) entered by the user exists in Administration.Account entity  or not. I have written a microflow and added a decision but can’t decide what expression should I write.
1 answers

In the microflow create an activity that retrieves the account from the database where the xpath looks something like:

[EmailID = $Registration/EmailID]

Then after this activity perfrom a aggregate action on the list and get the count, this will optimize the query to perform only the count of the records found.

Then in the decision write the statement like:

$count = 0

When this is true the emailid was not found, else the account using the emailid was found.