How can I change SP list text column type to lookup?

Copper Contributor

Hello everybody,


I'am currently importing some objets from an external MS application to make a PowerApp to sustitute it.


This objets have properties with the id relation between the objects.


I have researched and the unique way I found to create 'lookUp' columns is by creating a new one because the ones existing are not able to be updated.


For so, It looks like Is needed to:

  1. Create the new colum that will substitute the origin one
  2. Create a PowerAutomate flow that copies the data from each row to the origin to the new one

Is this right? In this case, anyone could share an example?

 

Thanks in advance,

4 Replies

@AlexBlanes you won't be able to do it with a flow in Power Automate, but there is a fairly simple solution depending on the number of items you have in the list. Create the new lookup column. Make sure the text column has only valid values that the lookup column can find (otherwise you'll get an error in the next step). Then go to Edit in grid view and select your text items in batches of no more than 100 and do a copy (ctrl+c). Then go to the first row in the lookup column and paste (ctrl+v).

 

texttoLU.png

Rob
Los Gallardos
Microsoft Power Automate Community Super User

@RobElliott 

Wow thanks. In my case I have to be in the grid view to be able to copy just the column I need.

 

Anyways this will take me a hole time. Now I've to copy two thousands but I have another object with eleven thousand elements with three relations... Are you sure is not possible to update with Power Automate?

 

 

@AlexBlanes yes I am because when you add the update item action, for the lookup column Power Automate  it describes it as, for example, AircraftTypeLU Id. If you just select the text column as a custom value for the lookup column it won't put anything at all into the column.

 

Rob
Los Gallardos
Microsoft Power Automate Community Super User

You can find many example on how to make it with powerautomate but you need to use a sharepoint get items to populate the lookup field@RobElliott