How to set the First day of the Week and the First Week of Year used in week functions in Spotfire Analyst or Web Player

How to set the First day of the Week and the First Week of Year used in week functions in Spotfire Analyst or Web Player

book

Article ID: KB0070644

calendar_today

Updated On:

Products Versions
Spotfire Analyst 11.6 and lower

Description

How to set the First day of the Week. If you see a different calculation result for week number or day, check if you have set the Firstday of week or first week of year correctly.

Issue/Introduction

How to set the First day of the Week and First Week of the year that is used in the Spotfire Week Function

Environment

Windows

Resolution

The culture/language which control how week numbers are calculated can be controlled with the two registry keys.

  • Run Regedit > Under HKEY_CURRENT_USER > Control Panel > International > iFirstDayOfWeek & iFirstWeekOfYear

Where

iFirstDayOfWeek:

0 - Monday

1 - Tuesday

2 - Wednesday

3 - Thursday

4 - Friday

5 - Saturday

6 - Sunday

 

iFirstWeekOfYear:

0 -Week containing January 1 is the first week of the year.

1 - First full week following January 1 is the first week of the year.

2 - First week containing at least four days is the first week of the year.

User-added image

NOTE:

  • If the analysis is accessed via the Analyst client this setting needs to be on the Analyst client user machine
  • If the analysis is accessed via the Web Player/browser, the update needs to be done only on the Node Manager Server for the Node Manager service account user.
This change is not applicable for versions 11.7 and higher. In those versions, a manual calculation of the week/day would be required.

NOTE:
In Spotfire 12.2, support for ISO Weeks and Years was introduced - see  https://community.spotfire.com/articles/spotfire/what-s-new-in-spotfire-12-2/

"Spotfire allows to format dates using ISO-8601 weeks and years standard to determine how data in a chart appears, and how it is used in calculations. ISO-8601 Week-Based calendar purpose is to provide an unambiguous and well-defined method of representing dates and times, which will avoid misinterpretation of numeric representations of dates and times, particularly when data transfer happens between countries with different conventions for writing numeric dates and times."

Additional Information

External: Update Registry Key (Change starting day of week in Windows ) via Powershell External: How to set the first day of the week in System tray calendar?