web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter Datatable based...
Power Apps
Answered

Filter Datatable based on the last four characters in column.

(0) ShareShare
ReportReport
Posted on by 62

Hi,

I have a datatable that displays records from a Sharepoint list as below.

 

Newbeetle1_0-1621689854242.png

 

The second column "Date." has text values that look like dates and I would like to filter these based on the last four characters that represent the year, based on a textInput box that returns the current Year as a text value using Text(Year( Now()))

 

I have currently set the table to filter on;

 

Filter('Toolbox Talk Monthly Returns', 'Date.' = TextInput1.Text)

 

If I place 30/12/1899 I can get the table to filter on this date but I want to have text box display all dates with the year within TextInput1 with Text(Year( Now()))

 

Any ideas welcomed.

 

 

 

Categories:
  • Verified answer
    CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @Newbeetle1 Use the following formula, but remember Right is non-delegable.

    Filter('Toolbox Talk Monthly Returns', Right('Date.',4) = Text(Year(Now())))
  • Newbeetle1 Profile Picture
    62 on at

    Thanks CNT, perfect.

  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @Newbeetle1 Glad to help!

     

    Please remember to give a 👍 and accept the solution as it will help others in the future.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 432 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 347

#3
WarrenBelz Profile Picture

WarrenBelz 254 Most Valuable Professional

Last 30 days Overall leaderboard