SSRS Second Function

The SSRS Second function is a Date and Time function that will extract the second of the minute from the given DateTime and return an integer from 0 to 59. The syntax of the Second function to extract the seconds from the Date and Time is as shown below.

=Second(Fields!OrderDate.Value)

To demonstrate the SSRS Second function, we use the Employee table below, which has 15 records. The image shows the records in the Table report.

Source Table

SSRS Second function Example

For this, let me add a new column to the right side of the Hire Date column and name it Seconds. Next, right-click the textbox under Second and choose Expression. To understand the report, I suggest you refer to the articles on charts, tables, grouping, and format tables in SSRS.

Choose the expression option

It opens the following expression window to print seconds. The Second function below extracts the Seconds value from the HireDate column and returns an integer value from 0 to 59 for each employee.

=Second(Fields!HireDate.Value)
SSRS Second Function expression to return the Seconds of the minute from the date and time field

Please click the preview tab to see the report. For more functions >> Click Here!

SSRS Second Function to return the Seconds of the minute from the date and time field preview