cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ahhollan
Helper V
Helper V

display next to last record in gallery

I need to display the next to the last record from a SharePoint list. What would be the gallery formula for that? 

 

thanks.

 

 

4 REPLIES 4
mdevaney
Super User III
Super User III

@ahhollan 

Like this...

 

Last(FirstN(Sort(your_datasource_name, ID, Descending),2)))

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

WarrenBelz
Super User III
Super User III

Hi @ahhollan ,

Assuming you don't delete records, you can use the ID number.

Your next record would be

Lookup(
   YourListName,
   ID = ThisItem.ID + 1
)

You also could keep your own numbered list and work off this.

 

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.

Try:
First(LastN(datasource,2))

@eka24 
FYI, your solution will trigger a delegation warning

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

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