Our story begins with 2 models:
“Members” : ordinary custom sObject model, condition where Id = Param.Id. Limit 100 records
"UtilityAccount" : custom sObject, condition where Id IN any row from "Members: model. Limit 1000
The trouble is that users weren’t getting warnings for bad data on page load if the error was on row #101 or greater. So I changed the limit on “Members” to 1000 records. Life was great in Userville, the page load was a drop slower but Users we’re so excited that they got errors on page load, that they barely noticed.
Suddenly the Apex Heap size error reared it’s ugly head. Users were frightened and disturbed by this. Anytime there were more than 500 or so “Members” the page wouldn’t load!
Enter the loadNextOffset method! This was added to the API recently, and I immediately spun up a snippet as detailed here: https://community.skuidify.com/skuid/topics/options_around_managing_large_datasets_and_apex_heap_siz… . Now my “Members” model loaded incrementally and all was peaceful.
But then the darkness returned, I could easily load my “Members” incrementally, but even when members went up to 100 or so records, “UtilityAccount” was still stuck at 100. This is because on the initial creation of the “UtilityAccount” model, “Members” only had 100 records. Although that had already increased to 1000, “UtilityAccount” was none the wiser!
I tried updating the “UtilityAccount” models data,
to no avail… the SOQL was still limited to the original 100 “Members” rows.
So I immediately scoured the
kingdom community, and found this post : https://community.skuidify.com/skuid/topics/how_do_i_refresh_updatedata_a_model_with_a_dependent_mod… . Just update simultaneously! It seemed great, just do a little something like this:
The problem is that my “Members” model is limited to 100 rows, so even when they are reloaded together, the limit 100 on the “Members” model doesn’t let the “UtilityAccount” model realize that there are more records. If I set the limit back to 1000, the page won’t load.
Faced with no other options, our hero sent out a desperate plea for help.
Sorry for all the randomness, I’m trying to make a lengthy question readable.