I have created a Model Driven app to work with Dataverse tables in Microsoft 365 PowerApps.
I am trying to export the data from my dev environment to test environment using export and import excel functionality.
Import from CSV works fine from Dataverse Tables section. But export and import from the Model Driven App view doesn't work. In this, import of data completes without any error but no rows are imported in the test environment. The Dataverse tables are part of the solution package so there is no difference in schema.
Is there anything I am missing for export and import to work within different environments?
Thank you!
When exporting data from one dataverse environment, 3 hidden fields are added to the sheet which should be GUID of the record, modified date and hash key of the record (based on last modified).
Guid as we know is primary key so when importing back Dataverse expects the guid to be present and if not present it fails saying record not available.
Other fields are meant to protect accidental override of data such that by the time when you exported to excel and import to excel if there was any modification to the records this hash key and modified date gets updated and blocks the import for these rows and fails during import.
To import the data into another environment these fields must be cleared and then imported into the target, so it is treated as new record and gets created.
You can look at import logs by going to Advanced Settings-> Data Management-> Imports to see why the rows failed.