Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
insandur
Helper II
Helper II

Incompatible types for comparison - Date,Text in dropdown items power apps

Hi ,

 

I have a sharepoint column (Date column) and when using it in the dropdown value.

 

When i goto items and add filter   Date =  dropdown.selected.Value i get a error   

"Incompatible types for comparison - Date,Text"  .  

1 ACCEPTED SOLUTION
AmiraBedh
Super User
Super User

I see that you are trying to compare a date value with a text value and since your SharePoint column is a date type and the dropdown returns a text value (dropdown.selected.Value), you need to either convert the text to a date or the date to a text, depending on your needs.

 

You can use the DateValue function to convert the text value from the dropdown to a date format before comparing it with your SharePoint date column.

 

Filter(
    YourSharePointList,
    DateColumn = DateValue(Dropdown.Selected.Value)
)

 


Proud to be a Power BI Super User !

Microsoft Community : https://docs.microsoft.com/en-us/users/AmiraBedhiafi
Linkedin : https://www.linkedin.com/in/amira-bedhiafi/
StackOverflow : https://stackoverflow.com/users/9517769/amira-bedhiafi
C-Sharp Corner : https://www.c-sharpcorner.com/members/amira-bedhiafi
Power BI Community :https://community.powerbi.com/t5/user/viewprofilepage/user-id/332696

View solution in original post

3 REPLIES 3
AmiraBedh
Super User
Super User

I see that you are trying to compare a date value with a text value and since your SharePoint column is a date type and the dropdown returns a text value (dropdown.selected.Value), you need to either convert the text to a date or the date to a text, depending on your needs.

 

You can use the DateValue function to convert the text value from the dropdown to a date format before comparing it with your SharePoint date column.

 

Filter(
    YourSharePointList,
    DateColumn = DateValue(Dropdown.Selected.Value)
)

 


Proud to be a Power BI Super User !

Microsoft Community : https://docs.microsoft.com/en-us/users/AmiraBedhiafi
Linkedin : https://www.linkedin.com/in/amira-bedhiafi/
StackOverflow : https://stackoverflow.com/users/9517769/amira-bedhiafi
C-Sharp Corner : https://www.c-sharpcorner.com/members/amira-bedhiafi
Power BI Community :https://community.powerbi.com/t5/user/viewprofilepage/user-id/332696

Thank You Amira,

 

It worked well without error in Items, However i get error in my collect variable for that Date column collection

insandur_0-1729229104338.png

 

what do you want to achieve here ?


Proud to be a Power BI Super User !

Microsoft Community : https://docs.microsoft.com/en-us/users/AmiraBedhiafi
Linkedin : https://www.linkedin.com/in/amira-bedhiafi/
StackOverflow : https://stackoverflow.com/users/9517769/amira-bedhiafi
C-Sharp Corner : https://www.c-sharpcorner.com/members/amira-bedhiafi
Power BI Community :https://community.powerbi.com/t5/user/viewprofilepage/user-id/332696

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.