web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Data Table from Power ...
Power Automate
Answered

Data Table from Power automate to Power App

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi 

 

I'm passing DataTable from Power App to Power Automate flow 

The Parameter which I Passed in the flow in power app is given below

 

Spoiler (Highlight to read)
Emptyglasses_5-1677731377579.png

 

 

 

Collect(
colSPlist,
'PR INTENT LIST'
);
ForAll(
colSPlist,
Patch(
'PR INTENT LIST',
Defaults('PR INTENT LIST'),
{
'Employee Name': User().FullName,
'Mail ID': User().Email,
'Entity ': Office365Users.UserProfileV2(User().Email).companyName,
'Material Code': ThisRecord.'Material Code',
'Type ': ThisRecord.'Type ',
Description: ThisRecord.Description,
'HSN Code ': ThisRecord.'HSN Code ',
'Make ': ThisRecord.'Make ',
UOM: ThisRecord.UOM,
'Unit Rate ': Value(ThisRecord.'Unit Rate '),
'Quantity ': Value(ThisRecord.'Quantity '),
Amount: Value(ThisRecord.Amount)
}
)
);
PRIntentTestScenarioFlow.Run(
JSON(
colSPlist,
JSONFormat.IncludeBinaryData & JSONFormat.IgnoreUnsupportedTypes
)
);
Clear(colSPlist)

 

The tabels are not recieving in the flow in  proper order 

I've taken the following steps to create a html table for my approvers 

Emptyglasses_0-1677729785376.png

 

Emptyglasses_3-1677729896506.png

 

 

Emptyglasses_1-1677729850787.png

 

Emptyglasses_4-1677729968064.png

 

 

Could Anyone please help me to get the table in the format which I shared in the screenshot (Power app Screen )

Or else any other way to customize this table 

Categories:
I have the same question (0)
  • v-chengfen-msft Profile Picture
    Microsoft Employee on at

    Hi @Anonymous ,

    Could you explain why you are using this piece of code?

    vchengfenmsft_0-1677736060133.png

    Is it to get the columns of the data source?
    If the data source contains data, it will also be collected and entered into colSPlist.
    In this way, when you are in Forall, the data that has been submitted to the data source will appear.

     

    The second question:

    From the screenshot you provided, we can see that some fields are empty.

    In the code you provided, the data is not collected into colSPlist.

    The Patch() you use is just the data source to submit the data to , but it is not collected into ColSplist, so when you use flow to submit, no data will appear.

     

    It is suggested here to fill in some attributes when you add each piece of data

    vchengfenmsft_1-1677736824502.png's OnSelect:

     

    Collect(
    colSPlist,
    {
    'Employee Name':User().FullName,
    'Mail ID': User().Email,
    'Entity ': Office365Users.UserProfileV2(User().Email).companyName,
    MaterialCode: ComboBox1_1.Selected.Result,
    Type: DataCardValue5_1.Text,
    Description: DataCardValue6_1.Text,
    HSNCode: DataCardValue7_1.Text,
    Make: DataCardValue8_1. Text,
    UOM : DataCardValue9_1.Text,
    Unit: DataCardValue10_1.Text,
    Quantity: DataCardValue11_1.Text,
    Amount: DataCardValue2_1.Text
    }
    ); ResetForm(Form1_1)

     

    vchengfenmsft_3-1677736958749.png's OnSelect

     

    ForAll(
    colSPlist,
    Patch(
    'PR INTENT LIST',
    Defaults('PR INTENT LIST'),
    {
    'Employee Name': User().FullName,
    'Mail ID': User().Email,
    'Entity ': Office365Users.UserProfileV2(User().Email).companyName,
    'Material Code': ThisRecord.'Material Code',
    'Type ': ThisRecord.'Type ',
    Description: ThisRecord.Description,
    'HSN Code ': ThisRecord.'HSN Code ',
    'Make ': ThisRecord.'Make ',
    UOM: ThisRecord.UOM,
    'Unit Rate ': Value(ThisRecord.'Unit Rate '),
    'Quantity ': Value(ThisRecord.'Quantity '),
    Amount: Value(ThisRecord.Amount)
    }
    )
    );
    PRIntentTestScenarioFlow.Run(
    JSON(
    colSPlist,
    JSONFormat.IncludeBinaryData & JSONFormat.IgnoreUnsupportedTypes
    )
    );
    Clear(colSPlist)

     

     

    Best Regards

    Cheng Feng

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Yah you were right 

    Data source which contains data are also be collected and entered into colSPlist.

    thanks for that advice

    onselect of add button I'm passing the following code , does it need to be changed  ?

    Patch(
    colSPlist,
    Defaults(colSPlist),
    {
    'Employee Name': DataCardValue1_1.Text,
    'Mail ID': DataCardValue3_1.Text,
    'Entity ': DataCardValue13_1.Text,
    'Material Code': ComboBox1_3.Selected.Result,
    'Type ': DataCardValue5_3.Text,
    Description: DataCardValue6_3.Text,
    'HSN Code ': DataCardValue7_3.Text,
    'Make ': DataCardValue8_3.Text,
    UOM: DataCardValue9_3.Text,
    'Unit Rate ': Value(DataCardValue10_3.Text),
    'Quantity ': Value(DataCardValue11_3.Text),
    Amount: Value(DataCardValue2_3.Text)
    }
    );
    ResetForm(Form1_3)

    And I need one more help from u also 

    Could u please help me to store those datatable values into a table in power automate flow 

    I'm getting an error in parse json schema 

    Not matter how many time i changed the schema it is still showing the same error 

    I' using power app V2

    Emptyglasses_0-1677739763622.png

     

     

    when ever I'm trying to convert the json string I'm getting the following error 

    Emptyglasses_1-1677739763831.png

     

    This is my json schema 

    {
        "type""object",
        "properties": {
            "type": {
                "type""string"
            },
            "items": {
                "type""object",
                "properties": {
                    "type": {
                        "type""string"
                    },
                    "properties": {
                        "type""object",
                        "properties": {
                            "Amount": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "Description": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "Entity": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""array",
                                        "items": {
                                            "type""string"
                                        }
                                    }
                                }
                            },
                            "HSNCode": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "MailID": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""array",
                                        "items": {
                                            "type""string"
                                        }
                                    }
                                }
                            },
                            "Make": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""array",
                                        "items": {
                                            "type""string"
                                        }
                                    }
                                }
                            },
                            "MaterialCode": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "Quantity": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "Title": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""array",
                                        "items": {
                                            "type""string"
                                        }
                                    }
                                }
                            },
                            "Type": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "UOM": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            },
                            "UnitRate": {
                                "type""object",
                                "properties": {
                                    "type": {
                                        "type""string"
                                    }
                                }
                            }
                        }
                    },
                    "required": {
                        "type""array",
                        "items": {
                            "type""string"
                        }
                    }
                }
            }
        }
    }
     Im getting following error 
    Emptyglasses_2-1677739763893.png

     

     

     

    Could you please help me to fix this json schema 

     

  • Verified answer
    v-chengfen-msft Profile Picture
    Microsoft Employee on at

    Hi @Anonymous ,

    Please use json() to format the value passed from power apps in Compose, and then copy its format for ParseJSON

    vchengfenmsft_0-1677742723523.png

     

     

    Best Regards

    Cheng Feng

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 304

#2
David_MA Profile Picture

David_MA 245 Super User 2026 Season 1

#3
Expiscornovus Profile Picture

Expiscornovus 243 Most Valuable Professional

Last 30 days Overall leaderboard