PA - Data collector Error: "Fetched too many rows from indicator source . Allowed: 50,000 fetched: " but Previewing on the Indicator Source gives a smaller (incorrect) count



PA Data collection jobs can error out or provide warnings based on the amount of data that is being collected for an indicator source. Although, if you click the Preview button on the Indicator Source, the count of the rows fetched is lesser than the value of the property ""

Error Text from the job logs "Performance Analytics > Data Collector > Job Logs":

"Fetched too many rows from indicator source <IndicatorSourceName>. Allowed: <SysPropertyValue> fetched: <NumberGreaterThanAllowed>"  


All Releases 


If there is a read ACL or a Query Business Rule on the Indicator Source table, the count from the Preview button may be different from the actual count. The records fetched by the Data Collection job is not restricted by ACLs or Business Rules.


Option 1:

- Select the "Admin Overrides" option on any read ACLs on the table.

- Add a condition on the query business rule(s) to not run for admin users by adding "!gs.hasRole('admin')" in the condition field.

After doing these changes, login as admin user and the Preview option should give the right count for the Indicator Source.


Option 2:

Replace the <Indicator_Source_Encoded_Query> and <TABLE_NAME> in the below script with the encoded query and table name for the indicator source and run the script from Scripts - Background.

To get the Encoded query from the Indicator source:

- Open the Indicator Source record for which you are getting the error.
- Click the Preview button
- Clock on the record count to open the records in a new tab
- Right click on the filter breadcrumb and select the 'Copy query' option.

var gr = new GlideRecord('<TABLE_NAME>'); 
gr.query();"Indicator source Row Count" gr.getRowCount());