cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
UI1222
Advocate II
Advocate II

Create CSV from a lookup column

Hi 

 

My problem is pretty simple, but i can't find the right solution. 

 

I need a CSV file with a product number (called ELVVSnumber) in the first column. Thats it.

 

My flow looks like this:

 Flow.PNG

 

When i put in the productnumber "ELVVSnummer" it returns the ID instead of the actual number. 

 

Like this:

csv.PNG

 

"ELVVSnummer" is a lookup column in CDS. 

 

How do i get the correct number in the CSV file? 

1 ACCEPTED SOLUTION

Accepted Solutions
v-bacao-msft
Community Support
Community Support

 

Hi @UI1222 ,

 

Whether the output of List records action contain Lookup column value? What you fill in here is lookup column id.

 

If the output of the List records action does not contain the lookup column value, you can consider the following method.

 

Initialize array variables to store the data that needs to be displayed in the CSV table. Traverse the output of List records action, use Get record action to get the data in lookup entity. Fill in the lookup column id in Get record action.

 

Append the fields to be displayed in the table to the array variable.

157.PNG158.PNG

 

Hope this helps.

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
sudharsan1985
Solution Sage
Solution Sage

Hi @UI1222 

You have to expand the lookup column to get the actual value. Try to use expand on the Get Item action or try to use 'Send Http Request to SharePoint' action to send the detailed query using REST API.

 

Hope it helps, please like it or mark it as a solution if it resolves your clarification or issue
-Sudharsan K...

Hope it helps, please like it or mark it as a solution if it resolves your clarification or issue
-Sudharsan K...
v-bacao-msft
Community Support
Community Support

 

Hi @UI1222 ,

 

Whether the output of List records action contain Lookup column value? What you fill in here is lookup column id.

 

If the output of the List records action does not contain the lookup column value, you can consider the following method.

 

Initialize array variables to store the data that needs to be displayed in the CSV table. Traverse the output of List records action, use Get record action to get the data in lookup entity. Fill in the lookup column id in Get record action.

 

Append the fields to be displayed in the table to the array variable.

157.PNG158.PNG

 

Hope this helps.

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (3,132)