Crystal Reports Online Training

Learn Online, Anytime, Anywhere

Step-by-step online tutorials.

1.06 Two-Pass Report Processing

Two-Pass Report Processing

Crystal Reports processes reports in two stages. This is called the Two-Pass Report Processing Model. The first pass creates the primary data to be printed. During the second pass this data is further processed to finalize it for printing.

The first pass is used to read individual records one at a time and calculate any formulas that use them. This pass will only calculate the formulas that are based on raw data within a record or that perform simple calculations. As each record is read and the formulas are calculated, the results are stored in a temporary file to be used during the second pass.

After the first pass is finished, Crystal Reports performs a second pass where it evaluates all summary functions on the data. This wasn’t possible during the first pass because all the data had not been read yet. During the second pass all the raw data has been read into the temporary file and it can be evaluated and summarized as a whole.

Understanding the type of data that is processed during the Two-Pass Processing Model is essential to being able to write formulas and summarize data. Different chapters throughout this book reference this model for explaining when you can and can’t use certain reporting functionality.

NOTE: I later wrote a much better explanation of Two-Pass Report Processing and included it in Chapter 1 of my book Crystal Reports Encyclopedia Volume 1.