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 / Recording attempts for...
Power Apps
Answered

Recording attempts for a quiz in SharePoint list

(0) ShareShare
ReportReport
Posted on by 39

I am trying to record the number of attempts people make in a quiz into a SP list column, the current formula I have is:

 

Set(
 varAttempts,
 With(
 {
 Attempts: Filter(
 'Email Services - Knowledge Check',
 Email = CurrentUser
 )
 },
 CountRows(Attempts)
 )
);
Patch(
 'Email Services - Knowledge Check',
 {
 Title: "Email Services - Knowledge Check",
 Participant: User().FullName,
 Email: CurrentUser,
 Score: Score & " / 10",
 'Duration (mins)': DateDiff(courseStartTime, Now(), TimeUnit.Minutes),
 Attempts: varAttempts + 1,
 Logon: Office365Users.UserProfileV2(User().Email).mailNickname
 }
)

 

 

And this works fine, however, the SP list is likely to gain over 2000 responses - will this formula still be able to work? I previously used this formula prior to the patch and this also worked but it had a delegation warning:

 

Set(varAttempts, CountRows(Filter('Email Services - Knowledge Check', Email=CurrentUser)));

 

 

I want to prevent any chance of data not being collected - which formula is best to use for records that could potentially exceed 2000 records?

 

Data source: 'Email Services - Knowledge Check'

Column with participants email: 'Email'

Column with attempts: 'Attempts'

Global variable: varAttempts

Global variable of user's email: CurrentUser

 

I appreciate your expertise

Categories:
I have the same question (0)
  • Verified answer
    EddieE Profile Picture
    4,650 Moderator on at

    @SHD001 

    Both formulas will only return a max of 2,000 records. The formula using With() won't show the delegation error but it's essentially there - for your purposes. 

     

    The best way to avoid exceeding the 2,000 record limit is to make sure your Filter always returns <2000 records, no matter what.

     

    For example, at the moment your filter filters on email. If this filter will always return <2000 records then you are set. However, if at some future point in time this filter will not work - eg only return 2000 records when there are 2500 records - then you need to setup your filter to accommodate this.

     

    One way I can think of is that if there are different quizzes that users do then you can add the QuizName to your filter as well.

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 345 Most Valuable Professional

#2
11manish Profile Picture

11manish 207 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 177

Last 30 days Overall leaderboard