sdmx3mdt / public-consultation

0 stars 0 forks source link

add Annotations within KeySet constraints to each key #54

Closed brainwasher closed 3 years ago

brainwasher commented 3 years ago

The request refers to AnnotableArtefacts in SDMX 3.0. It has been accepted that the Annotation construct is available to most of the SDMX structural artefacts (e.g. DSD, DataFlow). During one of our SDMX project we found the need of extending this approach. We are currently working on the ECB Single Metadata Management project, where one objective is to map the existing DataPointModel (DPM) expressed in the XBRL technical standard into the SDMX standard. The DPM/XBRL has different structure than standard SDMX. In the DPM the information is modelled in a combination of Measure + Dimension + Domain member. Members are ‘grouped’ under common semantic definition (domain) and the Dimension is a way of interpreting the member. In order to fully represent the DPM model we would need to map not only the modelling of the information but also the layout of it. The ECB reports are expressed in a two or more dimensional (DPM axis) tables. The tables are represented by rows and columns with optional z-axis for more than two dimensional table. During our workshops we have came to conclusion that the best way to represent the ECB DPM model in SDMX is by mapping DPM modelling into SDMX DataKeySets, where one dimension (axis) is represented by a partial key (SeriesKey). The issue we face is connected with the mapping of the rendering of it. SDMX does not have a dedicated place for it therefore we need to find a proper place for the information about the columns/rows labels, codes, the order and indent level to be able to represent the layout and structure of the DPM table. The most suitable place for it seems to be the Annotations of the partial keys (KeySets). The SDMX 3.0 version standard does not provide the possibility to annotate the Key. For the ECB project we would need to adjust the SDMX schema. The possible way of avoiding that is to propose to incorporate the Annotations to the KeySets. For this reason it seems profitious to allow Annotations at a lower level than Structural artefacts. This request is to add Annotation within KeySet. Below is an example of how it could be implemented:

<str:DataKeySet isIncluded="true">
    <str:Key>
====TO BE ADDED====
        <com:Annotations>
            <com:Annotation id="id">
                <com:AnnotationTitle>Annotation Title</com:AnnotationTitle>
                <com:AnnotationType>DISPLAY</com:AnnotationType>
            </com:Annotation>
        </com:Annotations>
===================

        <str:KeyValue id="DIM1">
            <str:Value>A</str:Value>
        </str:KeyValue>
        <str:KeyValue id="DIM2">
            <str:Value>B</str:Value>
        </str:KeyValue>
    </str:Key>
</str:DataKeySet>

For the example above we present the implementation for isIncluded=”true” but the Annotation would be applicable also to excluded KeySets (isIncluded=”false”). At this point the issue could be expanded for other lower-level artefacts, such as CubeRegions, DataKeySets, KeyConstrains).

sdmx3mdt commented 3 years ago

Annotations now supported at the constraint key level. image