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 / Trying to understand L...
Power Apps
Unanswered

Trying to understand Last, LastN etc.

(0) ShareShare
ReportReport
Posted on by 65

In Microsoft flow, I've defined Apply to all rule, and Append to string. Everything is ok here I guess.

a1.PNG

Now I've set up button action OnSelect() like that.

 

 

Set(varHistory; PrzyciskusługiPowerApps.Run(editItem).history);;
ClearCollect(
 colHistoryTemp;
 Split(
 varHistory;
 "|"
 )
);;
ForAll(
 colHistoryTemp;
 Collect(
 colHistory;
 {
 Date: DateTimeValue(
 First(
 Split(
 Result;
 ";"
 ).Result
 ).Result;
 "pl-PL"
 );
 Version: Last(
 FirstN(
 Split(
 Result;
 ";"
 ).Result;
 2
 ).Result
 ).Result;
 Editor: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 3
 ).Result
 ).Result;
 VER01: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 4
 ).Result
 ).Result;
 VER02: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 5
 ).Result
 ).Result;
 VER03: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 6
 ).Result
 ).Result;
 VER04: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 7
 ).Result
 ).Result;
 VER05: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 8
 ).Result
 ).Result;
 VER06: Last(
 FirstN( 
 Split(
 Result;
 ";"
 ).Result;
 9
 ).Result
 ).Result;
 Title: Last(
 Split(
 Result;
 ";"
 ).Result
 ).Result
 }
 )
);;
Sort(
 colHistory;
 Date;
 Descending
);;
Clear(colHistoryTemp);;
Set(_popup; true)

 

 

But last two items are wrong, VER06 shows in result as appended VER06+Title result (ex. "value06valueTitle"), and this wrong value is saved under VER06 and Title value. What's wrong?

 

//edit
Everything is ok, Microsoft Flow is having some issue while saving. 

Categories:
  • timl Profile Picture
    37,287 Super User 2026 Season 2 on at

    Hi @nottheOther 

    So just to clarify what you said in your edit, everything is working OK for you now, and the problem no longer exists?

  • nottheOther Profile Picture
    65 on at

    Yes. 

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 382 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 329

#3
WarrenBelz Profile Picture

WarrenBelz 187 Most Valuable Professional

Last 30 days Overall leaderboard