cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Copying items from one list to another with different column types.

Hi all

 

I've had a look into this but can't find a solid workable solution so wondering if flow is the answer.

 

I have two lists. List 1 we will call it is the master list. It has many columns all with lots of different column types like people fields and dates etc. List 2 is a back date list so has the same schema as list 1 BUT the column types are all text and date as this was from an excel import.

 

I would like to copy the items from list 2 onto list 1 without mismatching or causing the columns to duplicate etc. I'd like them to map to the columns in list 1 and retain the list 1 column types. 

 

Is there a good way to do this? I did 1 test and it just duplicated the columns because they were not the same type.

 

Any thoughts and solutions appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Copying items from one list to another with different column types.

Hi @Anonymous,

 

Could you please share a screenshot of your flow's configuration?

Could you please share more details about your two SharePoint lists (List 1 and List 2)?

 

I have created two SharePoint lists on my side and the data structure of it as below:

List 1:6.JPG

Note: The TaskName column is a Single line of text type column, the Executor column is a Person or Group type column and the Due Date column is a Date type column.

 

List 2:7.JPG

Note: The Name1 and Person1 are both Single line of text type column, the Date1 is Date type column. In addition, if you want to copy a text value (Person1) from List 2 into a Person or Group type column (Executor) within List 1, you should fill the email address of the person within the text column (Person1) of the List 1.

 

I have made a test on my side and please take a try with the following workaround:

  • Add a proper trigger, here I use Flow Button trigger.
  • Add a "Get items" action, specify Site Address and List Name set to List B (List 2).
  • Add a "Apply to each" action, input parameter set to output of "Get items" action.
  • Within "Apply to each" action, add a "Create item" action, specify Site Address and List Name set to List A (List 1). TaskName field set to Name1 dynamic content of the "Get items" action, Executor Claims field set to Person1 dynamic content of the "Get items" action as a custom value, the Due Date field set to Date1 dynamic content of the "Get items" action.

Image reference:8.JPG

The flow works successfully as below:9.JPG

 

10.JPG

 

 

Best regards,

Kris

 

 

 

 

 

 

Community Support Team _ Kris Dai
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

5 REPLIES 5
Highlighted

Re: Copying items from one list to another with different column types.

Hi @Anonymous,

 

Yes, you could create a flow that triggers on your master list and then run an create/update item to update your 2nd list. You will jsut need to make sure that for each value you collect the string representation of your data.

 

Quite often setting variable (see varibale connector for initilize variable and set variable) to the values that you want to copy and then in the update item use the variables. As you then look through the run history you will see what the values are that are coming out of your fields.

 

 

Highlighted
Community Support
Community Support

Re: Copying items from one list to another with different column types.

Hi @Anonymous,

 

Could you please share a screenshot of your flow's configuration?

Could you please share more details about your two SharePoint lists (List 1 and List 2)?

 

I have created two SharePoint lists on my side and the data structure of it as below:

List 1:6.JPG

Note: The TaskName column is a Single line of text type column, the Executor column is a Person or Group type column and the Due Date column is a Date type column.

 

List 2:7.JPG

Note: The Name1 and Person1 are both Single line of text type column, the Date1 is Date type column. In addition, if you want to copy a text value (Person1) from List 2 into a Person or Group type column (Executor) within List 1, you should fill the email address of the person within the text column (Person1) of the List 1.

 

I have made a test on my side and please take a try with the following workaround:

  • Add a proper trigger, here I use Flow Button trigger.
  • Add a "Get items" action, specify Site Address and List Name set to List B (List 2).
  • Add a "Apply to each" action, input parameter set to output of "Get items" action.
  • Within "Apply to each" action, add a "Create item" action, specify Site Address and List Name set to List A (List 1). TaskName field set to Name1 dynamic content of the "Get items" action, Executor Claims field set to Person1 dynamic content of the "Get items" action as a custom value, the Due Date field set to Date1 dynamic content of the "Get items" action.

Image reference:8.JPG

The flow works successfully as below:9.JPG

 

10.JPG

 

 

Best regards,

Kris

 

 

 

 

 

 

Community Support Team _ Kris Dai
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

Highlighted
Anonymous
Not applicable

Re: Copying items from one list to another with different column types.

Thank you for this detailed solution, I am going to give this a try and should it work will mark as resolved 🙂

Highlighted
Anonymous
Not applicable

Re: Copying items from one list to another with different column types.

Thank you, gonna try all the things suggested and will let you know how I get on 🙂

Highlighted
New Member

Re: Copying items from one list to another with different column types.

But... If i need to move attachments (more than one)?

Helpful resources

Announcements
Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Community Conference

Power Platform Community Conference

Find your favorite faces from the community presenting at the Power Platform Community Conference!

Top Solution Authors
Top Kudoed Authors
Users online (6,002)