Showing results for 
Search instead for 
Did you mean: 
Super User
Super User

Can I not drop and add column with the same name?

Why is this broken?



ClearCollect(NextDataItems,RenameColumns(FirstN(Filter(temporary_assign_wo,Updated<>2 And !IsBlank(_SNValve)  ),Value(TextInput6.Text)),"SN_List","SN_List_Del"));




This works fine if I give the new column a different name.

I initially used DropColumns() but it resulted in the same issue.  Renaming it out of the way doesnt work either.


@WarrenBelz ,

I also have an issue with Patch() with SQL tables.  I also cannot patch from a collection into an SQL table if ANY columns in the collection do not exist in the table.  It will give the error "ColumnName Does not Exist".  Even if I'm not patching to that particular column.  It fails.  This has been a real PiTA! I have blown like 4 days on this now.  I am now going to create ANOTHER collection, specifically created those columns that are necessary to generate SN_List.  Then try to Patch() that back into table.  I'm losing my bloody mind on this.

HI @martinav ,

When you say Patch from a collection, what is the code you are using (in Text please)

Super User
Super User

Hi @martinav ,

Just checking if you got the result you were looking for on this thread. Happy to help further if not.

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.



Nope, I didnt. I ended up having to make a collection and doing the formulas in a separate ForAll(Collect()) nested function to get it done.  Not my preference, but its a one-off activity, so it was good enough.

Thanks for your help.

Helpful resources

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (3,432)