# Tip: Cycle Point Format

**URL:** <https://cylc.discourse.group/t/tip-cycle-point-format/685>\
**Category:** Tips\
**Created:** [July 3, 2023, 12:52pm UTC](https://cylc.discourse.group/t/tip-cycle-point-format/685 "2023-07-03T12:52:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![oliver.sanders](https://yyz2.discourse-cdn.com/free1/user_avatar/cylc.discourse.group/oliver.sanders/32/110_2.png) [@oliver.sanders](https://cylc.discourse.group/u/oliver.sanders)\
**Post date:** [July 3, 2023, 12:52pm UTC](https://cylc.discourse.group/t/tip-cycle-point-format/685/1 "2023-07-03T12:52:47Z")

</div>

Cylc uses the [ISO8601](https://cylc.github.io/cylc-doc/stable/html/tutorial/scheduling/datetime-cycling.html#iso8601) time point syntax for cycle points.

For example, this workflow:

```ini
[scheduling]
    initial cycle point = 2020
    [[graph]]
        P1Y = @wall_clock => happy-new-year

[runtime]
    [[happy-new-year]]
        script = echo "Happy ${CYLC_TASK_CYCLE_POINT}!"

```

Will produce cycle points like this:

- 20200101T0000Z
- 20210101T0000Z
- 20220101T0000Z
- …

These cycle points are used to form task IDs and are passed into tasks using the `$CYLC_TASK_CYCLE_POINT` environment variable:

```console
$ cylc cat-log <id>//20200101T0000Z/happy-new-year
Happy 20200101T0000Z!

```

But this workflow only cycles once a year so having cycle point precision down to the minute isn’t very helpful. This is where the [cycle point format](https://cylc.github.io/cylc-doc/stable/html/reference/config/workflow.html#flow.cylc%5Bscheduler%5Dcycle%20point%20format) comes in, it allows us to change how the cycle point is presented. E.G. if we want the cycle point to just contain the year we could add these lines into the workflow configuration:

```ini
[scheduler]
    cycle point format = CCYY # Note: C=century, Y=year-of-century

```

This will now produce cycle points like:

- 2020
- 2021
- 2022
- …

This will change task IDs as well as the value of the `$CYLC_TASK_CYCLE_POINT` environment variable:

```console
$ cylc cat-log <id>//2020/happy-new-year/NN/
Happy 2020!

```

That’s better!

You can also use the `isodatetime` command (which is provided with Cylc) to extract information from ISO8601 time points e.g:

```console
$ isodatetime 20230703T1351Z --f 'CCYY'
2023

```
