The maximum you should set each value to is 99, so do not set any of the retention periods higher than 99.

Save your changes. From now on, the ST03 data will be retained in future for the number of days, weeks and months you have specified here.

620 and 640 systems:

For older 620 and 640 systems, the retention periods are set in a different way in ST03: Collector and Performance DB -> Performance Database -> Reorganization

Here you set the retention "For standard data:" on the left, which is standard ST03 data, and "For other data:" on the right as specified in the windows. The retention times for both are set below the windows: