SSRS Rnd Function

The SSRS Rnd function is a Mathematical function that returns a random number of Single data types. The syntax of the Rnd function to generate random numbers is as shown below.

=Rnd()
=Rnd(0)
=Rnd(-1)

To demonstrate the Rnd function in Reporting Services, we use the Products table below, which has 14 records. The image shows the records in the table report; the result is in an empty column.

Source Table

SSRS Rnd function Example

To do this, right-click the textbox under the Result Header and choose the Expression to open the window below. The Rnd function below will generate and return the random numbers.

  1. More Functions
  2. Charts
  3. Tables
  4. Format tables
  5. SSRS
=Rnd()
SSRS Rnd Function expression to generate random numbers

Please click the preview tab to see the Rnd report.

SSRS Rnd Function to generate random numbers report preview