User Focus Table Bug - New Record ID not being passed from source table to user focus table
I have a User Focus table that has worked without any issues for nearly a year. Today, a user let me know that records stopped appearing on their end partway through the day (the API_RunImport call needs to work for them to see the records on their end once created). The first 12 records they created worked fine, then suddenly, new records stopped behaving as expected.
After some investigation, I found that the problem is due to the Record ID (RID) from the source table not being written to the User Focus table. This breaks the subsequent API_RunImport, since there is no RID to tell the import which record to merge with. The workflow was still working fine earlier today, then stopped without any changes being made.
Context:
I am the only builder for this app and no one else has access to change fields or formulas.
No recent changes have been made to the fields involved. I have run several tests, but the RID ([Record ID#]) is consistently not being passed through anymore.
All other fields are still being written correctly to the User Focus table.
Workflow Summary:
User creates a new record in the Immature Plant Batches table.
A Formula-URL button is clicked, which triggers the logic below and reloads the form. The form is set to auto-save when redirected.
Here is the relevant portion of the formula:
var text ProductionAddUser = URLRoot() & "db/" & [_DBID_USER_FOCUS] & "?act=API_AddRecord"
& "&_fid_6=" & ToText(User())
& "&_fid_118=" & URLEncode([Record ID#])
& "&_fid_119=" & URLEncode([Plant - Strain])
& "&_fid_143=" & URLEncode([IMPB - Next Immature Plant Batch Suffix - Production]);
var text ProductionEditUser = URLRoot() & "db/" & [_DBID_USER_FOCUS] & "?act=API_EditRecord"
& "&key=" & ToText(User())
& "&_fid_118=" & URLEncode([Record ID#])
& "&_fid_119=" & URLEncode([Plant - Strain])
& "&_fid_143=" & URLEncode([IMPB - Next Immature Plant Batch Suffix - Production]);
var text ProductionEditOrCreateUser = If([Current User - User Exists?], $ProductionEditUser, $ProductionAddUser);
var text RunProductionImport = URLRoot() & "db/" & [_DBID_IMMATURE_PLANT_BATCHES] & "?act=API_RunImport&ID=14";
var text NewProductionBatch = URLRoot() & "db/" & Dbid() & "?a=API_GenAddRecordForm&dfid=15"
& "&_fid_57=" & URLEncode([Related Scheduled Task])
& "&_fid_77=" & URLEncode([Related Planned Harvest])
& "&_fid_17=" & URLEncode(Today())
& "&_fid_8=" & URLEncode([Related Planned Harvest - Location])
& "&ifv=1&hs=1" & "&z=" & Rurl();
var text ProductionBatch = $ProductionEditOrCreateUser
& "&rdr=" & URLEncode($RunProductionImport)
& URLEncode("&rdr=" & URLEncode($NewProductionBatch));
$ProductionBatch
Again, everything except for the RID from the source table not getting passed and written to the user focus table anymore. Without that RID, the import fails to find a matching record to merge.
Has anyone experienced something similar recently? Or does anyone have ideas why [Record ID#] might suddenly stop resolving mid-day when it was working previously?
Thanks in advance for any insight. I am really stumped here.