Last modified by Artur on 2025/08/19 10:43

From version 5.4
edited by Helena
on 2025/05/21 21:50
Change comment: There is no comment for this version
To version 6.1
edited by Helena
on 2025/05/21 21:55
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -499,104 +499,84 @@
499 499  **3. Determine [PERIOD_START]:**
500 500  Subtract one from the [PERIOD_VALUE] and multiply this by the [PERIOD_DURATION]. Add[[(% class="wikiinternallink wikiinternallink wikiinternallink wikiinternallink wikiinternallink" %)^^~[3~]^^>>path:#_ftn3]](%%) this to the [REPORTING_YEAR_BASE]. The result is the [PERIOD_START].
501 501  
502 -1. **Determine the [PERIOD_END]:**
503 -
502 +**4. Determine the [PERIOD_END]:**
504 504  Multiply the [PERIOD_VALUE] by the [PERIOD_DURATION]. Add^^3^^ this to the [REPORTING_YEAR_BASE] add^^3^^ -P1D. The result is the [PERIOD_END].
505 505  
506 506  For all of these ranges, the bounds include the beginning of the [PERIOD_START] (i.e. 00:00:00) and the end of the [PERIOD_END] (i.e. 23:59:59).
507 507  
508 -**Examples: **
507 +**Examples:**
509 509  
510 510  **2010-Q2, REPORTING_YEAR_START_DAY = ~-~-07-01 (July 1)**
511 -
512 512  ~1. [REPORTING_YEAR_START_DATE] = 2010-07-01
513 -
514 514  b) [REPORTING_YEAR_BASE] = 2010-07-01
515 -
516 -1. [PERIOD_DURATION] = P3M
517 -1. (2-1) * P3M = P3M
518 -
512 +[PERIOD_DURATION] = P3M
513 +(2-1) * P3M = P3M
519 519  2010-07-01 + P3M = 2010-10-01
520 -
521 521  [PERIOD_START] = 2010-10-01
522 -
523 523  4. 2 * P3M = P6M
524 -
525 525  2010-07-01 + P6M = 2010-13-01 = 2011-01-01
526 -
527 527  2011-01-01 + -P1D = 2010-12-31
528 -
529 529  [PERIOD_END] = 2011-12-31
530 530  
531 531  The actual calendar range covered by 2010-Q2 (assuming the reporting year begins July 1) is 2010-10-01T00:00:00/2010-12-31T23:59:59
532 532  
533 533  **2011-W36, REPORTING_YEAR_START_DAY = ~-~-07-01 (July 1)**
534 -
535 535  ~1. [REPORTING_YEAR_START_DATE] = 2010-07-01
536 -
537 537  a) 2011-07-01 = Friday
538 -
539 539  2011-07-01 + P3D = 2011-07-04
540 -
541 541  [REPORTING_YEAR_BASE] = 2011-07-04
542 -
543 -1. [PERIOD_DURATION] = P7D
544 -1. (36-1) * P7D = P245D
545 -
528 +2. [PERIOD_DURATION] = P7D
529 +3. (36-1) * P7D = P245D
546 546  2011-07-04 + P245D = 2012-03-05
547 -
548 548  [PERIOD_START] = 2012-03-05
549 -
550 550  4. 36 * P7D = P252D
551 -
552 552  2011-07-04 + P252D =2012-03-12
553 -
554 554  2012-03-12 + -P1D = 2012-03-11
555 -
556 556  [PERIOD_END] = 2012-03-11
557 557  
558 558  The actual calendar range covered by 2011-W36 (assuming the reporting year begins July 1) is 2012-03-05T00:00:00/2012-03-11T23:59:59
559 559  
560 -==== 4.2.7 Distinct Range ====
539 +=== 4.2.7 Distinct Range ===
561 561  
562 562  In the case that the reporting period does not fit into one of the prescribe periods above, a distinct time range can be used. The value of these ranges is based on the ISO 8601 time interval format of start/duration. Start can be expressed as either an ISO 8601 date or a date-time, and duration is expressed as an ISO 8601 duration. However, the duration can only be postive.
563 563  
564 -==== 4.2.8 Time Format ====
543 +=== 4.2.8 Time Format ===
565 565  
566 566  In version 2.0 of SDMX there is a recommendation to use the time format attribute to gives additional information on the way time is represented in the message. Following an appraisal of its usefulness this is no longer required. However, it is still possible, if required , to include the time format attribute in SDMX-ML. 
567 567  
568 -|**Code**|**Format**
569 -|**OTP**|Observational Time Period: Superset of all SDMX time formats (Gregorian Time Period, Reporting Time Period, and Time Range)
570 -|**STP**|Standard Time Period: Superset of Gregorian and Reporting Time Periods
571 -|**GTP**|Superset of all Gregorian Time Periods and date-time
572 -|**RTP**|Superset of all Reporting Time Periods
573 -|**TR**|Time Range: Start time and duration (YYYY-MMDD(Thh:mm:ss)?/<duration>)
574 -|**GY**|Gregorian Year (YYYY)
575 -|**GTM**|Gregorian Year Month (YYYY-MM)
576 -|**GD**|Gregorian Day (YYYY-MM-DD)
577 -|**DT**|Distinct Point: date-time (YYYY-MM-DDThh:mm:ss)
578 -|**RY**|Reporting Year (YYYY-A1)
579 -|**RS**|Reporting Semester (YYYY-Ss)
580 -|**RT**|Reporting Trimester (YYYY-Tt)
581 -|**RQ**|Reporting Quarter (YYYY-Qq)
582 -|**RM**|Reporting Month (YYYY-Mmm)
583 -|**Code**|**Format**
584 -|**RW**|Reporting Week (YYYY-Www)
585 -|**RD**|Reporting Day (YYYY-Dddd)
547 +(% style="width:1049.29px" %)
548 +|**Code**|(% style="width:926px" %)**Format**
549 +|**OTP**|(% style="width:926px" %)Observational Time Period: Superset of all SDMX time formats (Gregorian Time Period, Reporting Time Period, and Time Range)
550 +|**STP**|(% style="width:926px" %)Standard Time Period: Superset of Gregorian and Reporting Time Periods
551 +|**GTP**|(% style="width:926px" %)Superset of all Gregorian Time Periods and date-time
552 +|**RTP**|(% style="width:926px" %)Superset of all Reporting Time Periods
553 +|**TR**|(% style="width:926px" %)Time Range: Start time and duration (YYYY-MMDD(Thh:mm:ss)?/<duration>)
554 +|**GY**|(% style="width:926px" %)Gregorian Year (YYYY)
555 +|**GTM**|(% style="width:926px" %)Gregorian Year Month (YYYY-MM)
556 +|**GD**|(% style="width:926px" %)Gregorian Day (YYYY-MM-DD)
557 +|**DT**|(% style="width:926px" %)Distinct Point: date-time (YYYY-MM-DDThh:mm:ss)
558 +|**RY**|(% style="width:926px" %)Reporting Year (YYYY-A1)
559 +|**RS**|(% style="width:926px" %)Reporting Semester (YYYY-Ss)
560 +|**RT**|(% style="width:926px" %)Reporting Trimester (YYYY-Tt)
561 +|**RQ**|(% style="width:926px" %)Reporting Quarter (YYYY-Qq)
562 +|**RM**|(% style="width:926px" %)Reporting Month (YYYY-Mmm)
563 +|**Code**|(% style="width:926px" %)**Format**
564 +|**RW**|(% style="width:926px" %)Reporting Week (YYYY-Www)
565 +|**RD**|(% style="width:926px" %)Reporting Day (YYYY-Dddd)
586 586  
587 - **Table 1: SDMX-ML Time Format Codes**
567 +**Table 1: SDMX-ML Time Format Codes**
588 588  
589 -==== 4.2.9 Transformation between SDMX-ML and SDMX-EDI ====
569 +=== 4.2.9 Transformation between SDMX-ML and SDMX-EDI ===
590 590  
591 591  When converting SDMX-ML data structure definitions to SDMX-EDI data structure definitions, only the identifier of the time format attribute will be retained. The representation of the attribute will be converted from the SDMX-ML format to the fixed SDMX-EDI code list. If the SDMX-ML data structure definition does not define a time format attribute, then one will be automatically created with the identifier "TIME_FORMAT".
592 592  
593 -When converting SDMX-ML data to SDMX-EDI, the source time format attribute will be irrelevant. Since the SDMX-ML time representation types are not ambiguous, the target time format can be determined from the source time value directly. For example, if the SDMX-ML time is 2000-Q2 the SDMX-EDI format will always be 608/708 (depending on whether the target series contains one observation or a range of observations)
573 +When converting SDMX-ML data to SDMX-EDI, the source time format attribute will be irrelevant. Since the SDMX-ML time representation types are not ambiguous, the target time format can be determined from the source time value directly. For example, if the SDMX-ML time is 2000-Q2 the SDMX-EDI format will always be 608/708 (depending on whether the target series contains one observation or a range of observations).
594 594  
595 595  When converting a data structure definition originating in SDMX-EDI, the time format attribute should be ignored, as it serves no purpose in SDMX-ML.
596 596  
597 597  When converting data from SDMX-EDI to SDMX-ML, the source time format is only necessary to determine the format of the target time value. For example, a source time format of will result in a target time in the format YYYY-Ss whereas a source format of will result in a target time value in the format YYYY-Qq.
598 598  
599 -==== 4.2.10 Time Zones ====
579 +=== 4.2.10 Time Zones ===
600 600  
601 601  In alignment with ISO 8601, SDMX allows the specification of a time zone on all time periods and on the reporting year start day. If a time zone is provided on a reporting year start day, then the same time zone (or none) should be reported for each reporting time period. If the reporting year start day and the reporting period time zone differ, the time zone of the reporting period will take precedence. Examples of each format with time zones are as follows (time zone indicated in bold):
602 602  
... ... @@ -617,7 +617,7 @@
617 617  
618 618  According to ISO 8601, a date without a time-zone is considered "local time". SDMX assumes that local time is that of the sender of the message. In this version of SDMX, an optional field is added to the sender definition in the header for specifying a time zone. This field has a default value of 'Z' (UTC). This determination of local time applies for all dates in a message.
619 619  
620 -==== 4.2.11 Representing Time Spans Elsewhere ====
600 +=== 4.2.11 Representing Time Spans Elsewhere ===
621 621  
622 622  It has been possible since SDMX 2.0 for a Component to specify a representation of a time span. Depending on the format of the data message, this resulted in either an element with 2 XML attributes for holding the start time and the duration or two separate XML attributes based on the underlying Component identifier. For example if REF_PERIOD were given a representation of time span, then in the Compact data format, it would be represented by two XML attributes; REF_PERIODStartTime (holding the start) and REF_PERIOD (holding the duration). If a new simple type is introduced in the SDMX schemas that can hold ISO 8601 time intervals, then this will no longer be necessary. What was represented as this:
623 623  
... ... @@ -627,30 +627,29 @@
627 627  
628 628  <Series REF_PERIOD="2000-01-01T00:00:00/P2M"/>
629 629  
630 -==== 4.2.12 Notes on Formats ====
610 +=== 4.2.12 Notes on Formats ===
631 631  
632 632  There is no ambiguity in these formats so that for any given value of time, the category of the period (and thus the intended time period range) is always clear. It should also be noted that by utilizing the ISO 8601 format, and a format loosely based on it for the report periods, the values of time can easily be sorted chronologically without additional parsing.
633 633  
634 -==== 4.2.13 Effect on Time Ranges ====
614 +=== 4.2.13 Effect on Time Ranges ===
635 635  
636 636  All SDMX-ML data messages are capable of functioning in a manner similar to SDMX-EDI if the Dimension at the observation level is time: the time period for the first observation can be stated and the rest of the observations can omit the time value as it can be derived from the start time and the frequency. Since the frequency can be determined based on the actual format of the time value for everything but distinct points in time and time ranges, this makes is even simpler to process as the interval between time ranges is known directly from the time value.
637 637  
638 -==== 4.2.14 Time in Query Messages ====
618 +=== 4.2.14 Time in Query Messages ===
639 639  
640 640  When querying for time values, the value of a time parameter can be provided as any of the Observational Time Period formats and must be paired with an operator. In addition, an explicit value for the reporting year start day can be provided, or this can be set to "Any". This section will detail how systems processing query messages should interpret these parameters.
641 641  
642 642  Fundamental to processing a time value parameter in a query message is understanding that all time periods should be handled as a distinct range of time. Since the time parameter in the query is paired with an operator, this is also effectively represents a distinct range of time. Therefore, a system processing the query must simply match the data where the time period for requested parameter is encompassed by the time period resulting from value of the query parameter. The following table details how the operators should be interpreted for any time period provided as a parameter.
643 643  
644 -|**Operator**|**Rule**
645 -|Greater Than|Any data after the last moment of the period
646 -|Less Than|Any data before the first moment of the period
647 -|Greater Than or Equal To|(((
648 -Any data on or after the first moment of
649 -
650 -the period
624 +(% style="width:1024.29px" %)
625 +|(% style="width:238px" %)**Operator**|(% style="width:782px" %)**Rule**
626 +|(% style="width:238px" %)Greater Than|(% style="width:782px" %)Any data after the last moment of the period
627 +|(% style="width:238px" %)Less Than|(% style="width:782px" %)Any data before the first moment of the period
628 +|(% style="width:238px" %)Greater Than or Equal To|(% style="width:782px" %)(((
629 +Any data on or after the first moment of the period
651 651  )))
652 -|Less Than or Equal To|Any data on or before the last moment of the period
653 -|Equal To|Any data which falls on or after the first moment of the period and before or on the last moment of the period
631 +|(% style="width:238px" %)Less Than or Equal To|(% style="width:782px" %)Any data on or before the last moment of the period
632 +|(% style="width:238px" %)Equal To|(% style="width:782px" %)Any data which falls on or after the first moment of the period and before or on the last moment of the period
654 654  
655 655  Reporting Time Periods as query parameters are handled based on whether the value of the reportingYearStartDay XML attribute is an explicit month and day or "Any":
656 656