This information can be obtained from the gateway by using the Gateway-SQL plugin. The queries work by counting the total number of plugins used by each probe or managed entity. Example of the dataviews are listed below. The xml of the sampler is attached at the bottom.
1-Depending on the estate of your gateway the sampler may be expensive in terms of performance and take some time to run.
2-Due to the above reason, the sampler is configured on purpose NOT to sample on startup and does not run on its own. It has a 0 sampling interval. As a result, you will see 0 rows, Manual sampling in the dataview when the sampler is initialized.
3-To run the sampler manually, click on the sample now or refresh icon in one of the dataviews and data will be populated in both dataviews.