INTERVAL statement


The INTERVAL statement specifies the time interval that applies to data in reports that subsequent REPORT statements in the same job stream produce.

If the report specifies a default interval, the INTERVAL statement overrides it.

Related topics

When you use INTERVAL as a parameter in the REPORT statement, the specified interval relates only to the reports that the REPORT statement specifies. The INTERVAL parameter overrides a default interval and any previously specified INTERVAL statement.

Important

You can specify multiple time periods for the Batch SQL Comparison Analysis report (SQMBDIFF) report.

Valid abbreviations for INTERVAL are INT and I.

One of the following options determines the date format in the INTERVAL specification:

  • Global option called Site date formatting style option (acts as the default for all users)
  • User Profile Presentation Options field called Date formatting style option (overrides the global default)
  • User Options Presentation Options field called Date formatting style option (overrides the User Profile specification)

The valid date formats for the START and END keywords are as follows:

Date format

Description

USA format

You can specify the date in one of the following formats:

  • mm/dd/yyyy
  • mm/dd/yy
  • mm/dd

European format

You can specify the date in one of the following formats:

  • dd/mm/yyyy
  • dd/mm/yy
  • dd/mm

ISO format

You can specify the date in one of the following formats:

  • yyyy/mm/dd
  • yy/mm/dd

Important

If you use the ISO format, you must specify the year.

 Consider the following points when specifying a date and time:

  • You can specify the year in a two-digit or four-digit format.
  • If you specify the year as two digits, Data Collector interprets 00–36 as 2000–2036, and 81–99 as 1981–1999. Values 37–80 are invalid.
  • If you specify a date without yy or yyyy, the year defaults to the current year (USA and European formats only).
  • You can specify the date format by preceding the date with one of the following characters:
    • U (USA format)
    • E (European format)
    • I (ISO format)
  • You can specify time by using one of the following formats:
    • hh:mm:ss (hours, minutes, and seconds)
    • hh:mm (hours and minutes)
Example

The following example uses a USA format to request a reporting interval from March 1, 2022 at 10 P.M. to March 31, 2016 at 10 P.M.:

INTERVAL(START(U03/01/22,22:00),END(U03/31/22,22:00)

The following example uses a European format to specify the same interval:

INTERVAL(START(E01/03/22,22:00),END(E31/03/22,22:00)

This section contains the following topics:


 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*