cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper I
Helper I

Need Unique array from List Records

From the Invoice entity we need unique array of customers,

we tried using variables and union for the same.

However we are not able to get the array with only Guids.

 

We tried splits function as well

Requirements : get array of unique customers from List of invoices.

1 ACCEPTED SOLUTION

Accepted Solutions
Advocate II
Advocate II

Hey @Achavan

 

I tried to solve your problem by implementing the same scenario using the Account and Contact entity.

 

Account-->Invoice

Contact-->Customer

 

After you list all the invoice records using the List Record action, Use the "Apply to each" action to loop all the records. Try to get the guid of every customer and add it to the array variable.

 

After the for-each loop usea compose action to get the unique value by below exp.

 

Expression:-

union(variables('Array'),variables('Array'))

 

 

Screenshot of the flow:-

 

acc.PNG

 For getting the Guid I used following Expression:

item()?['_primarycontactid_value']

 

 

I hope I am able to help you to solve the issue. Let me know if I can further help you out.

 

Accept this as a solution if you think the above content fulfills your request.

 

Thank You 

Naveen Gupta

View solution in original post

5 REPLIES 5
Super User III
Super User III

Hi!

Is 'List of invoices' a sharepoint list? An excel table?

If SP, which column type do you want to consolidate their current values? Is it 'single line of text', choice, lookup...?

 

In case of excel, here you are an example of how to implement it

https://powerusers.microsoft.com/t5/Building-Flows/Consolidated-email-based-on-date-in-excel/m-p/471...

Thanx



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Hi, 

we want unique array of Customers from list records (cds connector) 

 
 
Advocate II
Advocate II

Hey @Achavan

 

I tried to solve your problem by implementing the same scenario using the Account and Contact entity.

 

Account-->Invoice

Contact-->Customer

 

After you list all the invoice records using the List Record action, Use the "Apply to each" action to loop all the records. Try to get the guid of every customer and add it to the array variable.

 

After the for-each loop usea compose action to get the unique value by below exp.

 

Expression:-

union(variables('Array'),variables('Array'))

 

 

Screenshot of the flow:-

 

acc.PNG

 For getting the Guid I used following Expression:

item()?['_primarycontactid_value']

 

 

I hope I am able to help you to solve the issue. Let me know if I can further help you out.

 

Accept this as a solution if you think the above content fulfills your request.

 

Thank You 

Naveen Gupta

View solution in original post

Thank you @Naveen_772 

 

can you help me to create two dimentional array of Account and Contact from Opportunity

Hey @Achavan 

 

I am happy to help.

 

Thank You

Helpful resources

Announcements
PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Top Solution Authors
Users online (10,902)