cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Sriks
Level: Powered On

SortByColumns, specified column does not exists

Hello, I am using the SortByColumns function inside the "items" field of a gallery to sort my gallery by date (gallery created from a sharepoint list).

I got two date variables, same format (created using another app and putting same data in two variables whith Patch, 'Delai' and 'Delai_nouv').

 

Problem here is that :

SortByColumns('Informations demandes', "Delai", If(SortDescending1, Descending, Ascending))

is working, and that :

SortByColumns('Informations demandes', "Delai_nouv", If(SortDescending1, Descending, Ascending))

is creating the error :

The specified column 'Delai_nouv' does not exist.

whereas inside my gallery, ThisItem.Delai_nouv is working while using the same connexion to my sharepoint list.

 

I tried updating my list using View -> Data Sources.

I also tried deleting the connexion and recreating it.

 

I hope someone got a workaround cause i don't want to recreate my app from scratch.

Thanks in advance !

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: SortByColumns, specified column does not exists

Hi,

 

This might be an issue to do with renaming the column as SortByColumn uses 'base' column names:

If you open the SharePoint List

> 'Cog' Settings

> List Settings

> Click on that Column to edit its properties

 - now in the Titlebar you will see something like this:

image.png

 

This will list the 'base' field name that the field was called before it was renamed - this is what is needed when using SharePoint column names surrounded by " "

 

Please could you try using this and let me know if this works,

 

Cheers,

ManCat

 




Don't forget to 'Mark as Solution' if a post answered your question and always 'Thumbs Up' the posts you like or helped you!

View solution in original post

3 REPLIES 3
Super User
Super User

Re: SortByColumns, specified column does not exists

Hi,

 

This might be an issue to do with renaming the column as SortByColumn uses 'base' column names:

If you open the SharePoint List

> 'Cog' Settings

> List Settings

> Click on that Column to edit its properties

 - now in the Titlebar you will see something like this:

image.png

 

This will list the 'base' field name that the field was called before it was renamed - this is what is needed when using SharePoint column names surrounded by " "

 

Please could you try using this and let me know if this works,

 

Cheers,

ManCat

 




Don't forget to 'Mark as Solution' if a post answered your question and always 'Thumbs Up' the posts you like or helped you!

View solution in original post

Sriks
Level: Powered On

Re: SortByColumns, specified column does not exists

Thank you for answering.

It was indeed the original field name that was still saved somewhere.

I successfully renamed it going to the list parameters and editing the column parameters there. 

I now can call the column by the modified name.

 

It's still strange that editing the title of a column inside of the list isn't doing the same thing as editing it inside the list parameters..

 

Thanks,

Sriks

Highlighted
Super User
Super User

Re: SortByColumns, specified column does not exists

Hi,

 

Yes it's a 'SharePoint quirk' - I've written about it in more detail here:

https://powerusers.microsoft.com/t5/General-Discussion/Field-name-size-limit/m-p/57728/thread-id/238...

 

Cheers,

ManCat




Don't forget to 'Mark as Solution' if a post answered your question and always 'Thumbs Up' the posts you like or helped you!

Helpful resources

Announcements
thirdimage

Power Apps Super User Class of 2020

Check it out!

thirdimage

New Badges

Check it out!

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

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