Import Data with Multi-choice Columns to Dataverse (New Import UI)

Let’s try to import data to Dynamics 365/Power App! How difficult could it be, right? Right?!

I successfully imported a CSV file with simple text and even choice columns via the app’s import UI. Unfortunately, I needed to import data with the multiple-choice columns. And it turned out to be an absolute nightmare.

Unfortunately, my favorite dataflows don’t support multi-choice. Let me know if I am wrong and missed something. Happy to be wrong in this case.

 I decided to write a blog post to help you save time.

In my example, I have a multi-choice column, Sector of Interests.

List contacts with sectors of interest

Also, I have a CSV file I would like to import.

Screenshot of the Excel data file with contact columns like First Name, Last NAme, Mobile, DOB, Email, Sectors of Interest

Let’s fail fast! Let’s try the app import UI first.

Going through the normal wizard steps here.

Oops! This doesn’t look right.

It is trying to map every Sector of Interest cell for each row. I don’t think it’s going to work. (I tried it, it didn’t).

So what’s next?

Fortunately, we have admin tools with slightly more powerful features. Let’s go there!

Top menu, right corner, Settings icon. Select Advanced Setting from the context menu.

Left side menu  ->  System  -> Data Management.

Choose Templates for data import.

What could possibly go wrong?

It went wrong pretty quickly. Fortunately, I know how to fix it. This message means you have to columns with the same display name in the table. Let’s find them!

If you have access to the maker portal, it will be easy to do; if you don’t, you have to ask for help.

On the maker portal, go to Solutions, then pick the Default solution. Under Tables, find your table, then display all columns.

Bad news: I don’t know a good way to spot duplicates. Good news: I could do it so I hope you will be able too.

Rename one of the columns. It will create this terrible thing, an Unmanaged layer. But we will deal with it later.

Save, and don’t forget to Publish the Table via Advanced from the top menu options.

Going back to the Advanced Settings, then System -> Data Management. Choose Templates for Data Import. Then pick up Contact and click Download.

Hope it worked this time, fingers crossed.

Open the template downloaded.

It should look like this:

Now, just follow my steps:

Delete all the columns you don’t have in the file you are trying to upload.

Mine looks like this.

Now you have to copy data across; be careful not to break the template.

This is the result, and we are ready to upload.

From the Data Management area, choose Imports.

From the top menu click on Import data. Follow the wizard steps.

For the Choose file, use your populated template, not the original CSV file.

Don’t change anything here unless you know what you are doing.

Click Next.

NOW. In the old wizard, you skipped the step if you use a template, but here – NOPE.

Select Entity Mapping table. Mine is Contact.

If.You.Did.Everything.Correctly. you should only see your columns.

Notice how multichoice mapping looks healthy: it’s not trying to map every Sector of Interest row from my file.

If you did everything correctly. Click Next and watch the magic happening.

Seeing the next screen is practically like seeing the screen YOU WON!

Click OK. Then Finish on the next screen.

You could monitor the import outcome on this screen or go drink a cup of coffee, then come back later. Import is an async operation; it may take some time.

Check for the Status Reason Completed in the list.

I have 1 error. Click on the record to see the details.

In my case, it’s a duplicate error. Remember, we didn’t toggle the Allow Duplicates button during the wizard screens. Well done to us! Duplicates are not good.

Well, this is finally it.

Two things I want to suggest at the end.

One: for the large file (after the first import attempt failed), try smaller chunks. It will be easy to spot data issues.

Two: make sure your choice options match the items in the multiple-choice exactly. If it doesn’t match, it may still work. Or it may not. If you have time to explore – go ahead!

Regardless, congratulations on completing the mission!

(This article was created by a human. The information in the article is based on the author’s real-life consulting experience and reflects the author’s perspective on aspects of life and technology: subjective, unfiltered, and genuine.)

Leave a Reply

Discover more from Technomancy

Subscribe now to keep reading and get access to the full archive.

Continue reading