When creating a new Bex query and saving it, the RSZ* tables are filled by the query definition functions. This information from the front-end has to be translated for the OLAP-processor. This is done to ensure good performance during query processing and also to check definition problems before running a query.
Running a query it is checked if this query has existed before, is newly created, underwent only some changes (to itself or needed objects like the inoprovider) or has not been changed at all. This is done in the report: RRI_REPORT_IMPORT_AND_CHECK. The important flag to watch is newgen (1=NO_CHANGE, 2=REPORT, 3=GENERATE, 4=ALL) filled in the method cl_rsr_report_check=>check.
Based on this a generation of the BEx query ABAP report is triggered.
The Generation Log can be used to analyse then when and why of such a generation taking place.