Arc - Record counter

Is it possible for Arc to show the number of records that have been processed, similar to the status window in Perspectives TI editor?

Hi @smbarnes,

As far as I know that isn’t possible as the REST API doesn’t provide a call back to get that information.

If there is not a REST API command, would it not be possible to setup a counter variable and increment it on the metadata tab and data tabs and ping it every 30 seconds to get a record count, and display that within Arc?

Hi @smbarnes,

That isn’t something we would put in to Arc itself. I am not sure it would work as the insert would be in a separate transaction so you may not be able to get the updated value until the process completes.

Hi @smbarnes,

You can leverage the LogOutput function to log process progress every N seconds:

TI code:

# Progress logging frequency in seconds
cProgressLogFrequency = 10;

IF( pDoProcessLogging @= '1' );
  nDataRecordCount = nDataRecordCount + 1;
  If (nDataRecordCount = 1);
    nDataStartTime = Now() * 24 * 3600;
    nDataProgressTime = 0;
  Else;
    nDataElapsedTime = (Now() * 24 * 3600) - nDataStartTime;
    If (nDataElapsedTime - nDataProgressTime >= cProgressLogFrequency);
      nDataProgressTime = nDataProgressTime + cProgressLogFrequency;
      LogOutput('INFO', 'Process "' | GetProcessName() | '" is processing Data 🏹 ' 
        | NumberToStringEx(nDataRecordCount, '#,##0', '.', ',') | ' records processed in '
        | NumberToStringEx(nDataElapsedTime, '#,##0', '.', ',') | ' seconds (⚡' 
        | NumberToStringEx(nDataRecordCount \ nDataElapsedTime, '#,##0', '.', ',') | ' rec/s).');
    EndIf;
  EndIf;
EndIF;
4 Likes