Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete messages #3

Open
sosna opened this issue Feb 28, 2020 · 7 comments
Open

Delete messages #3

sosna opened this issue Feb 28, 2020 · 7 comments
Assignees

Comments

@sosna
Copy link
Member

sosna commented Feb 28, 2020

Handling incremental deletion of messages in SDMX-ML is described in Section 3A, Part IV, page 69.

The last sentence in that section looks sub-optimal. It reads as follows: "Finally, to delete a data attribute or observation value it is recommended that the value to be deleted be supplied; however, it is only required that any valid value be provided."

This looks sub-optimal considering that, in order to delete a particular attribute value, all I need to know is the attribute ID and the key of the element to which that attribute is attached. This simple, logical way is how SDMX-EDI works by the way. So, why, in SDMX-ML, are we asked to supply the attribute value? Worse, why is it OK to supply "any valid value", which is even more confusing?

For structure specific message, the XML specification allows empty attribute values (e.g. CONF_STATUS=""), so there is no technical reason why the attribute value must be provided.

For generic messages, the current syntax is as follows:

<generic:Value id="BIS_TOPIC" value="ABBA"/>

In that case as well, it would be sufficient in delete messages to write:

<generic:Value id="BIS_TOPIC" />

The only reason we could think of is that the schema generated for structure specific messages would need to be dependent on the action, i.e. there would be one schema for delete messages and one schema for the other action types. This can easily be addressed in the RESTful API though, by adding an action parameter to schema queries.

Maybe that this could be addressed within the scope of SDMX 3.0?

@dosse
Copy link
Contributor

dosse commented Mar 2, 2020

I agree with you that deletions are a "sub-optimal". This topics links also to the discussions on handling of missing/not-provided values in SDMX-ML/JSON messages with actions "REPLACE" and "INFO", as well as in SDMX-CSV messages.
Supporting different schema types might not be sufficient to solve this for generic SDMX-ML messages, because a message can contain several datasets with each a different action (e.g. as a result of includeHistory). Another solution would be to be less strict with the presence of values (as done for structure-specific messages).

@sosna
Copy link
Member Author

sosna commented Mar 3, 2020

Thanks, @dosse!

I believe that having multiple datasets in the response will not be a problem. The issue is similar with dimensionAtObservation: There as a well, the schema will vary depending on how the data are packaged (as time series, flat or cross-sectional messages).

The way this was addressed for dimensionAtObservation was to make the "packaging information" part of the URN, for example:

urn:sdmx:org.sdmx.infomodel.datastructure.DataStructure=ESTAT:NA_MAIN(1.10):ObsLevelDim:TIME_PERIOD

The URN is used as key to the schema and so, multiple datasets (in the same message) may very well reference different schemas.

The same could be achieved in this case, as long as the action is made part of the URN.

What do you think?

@dosse
Copy link
Contributor

dosse commented Jun 5, 2020

@sosna Sounds good!

dosse pushed a commit that referenced this issue May 5, 2021
Replace SDMX 2.1 Section 3A document with updated versions for SDMX 3.0
* Delete SDMX_2-1_SECTION_3A_PART_III_STRUCTURE.doc
* Delete SDMX_2-1_SECTION_3A_PART_II_COMMON.doc
* Delete SDMX_2-1_SECTION_3A_PART_IV_DATA.doc
* Delete SDMX_2-1_SECTION_3A_PART_I_MESSAGE.doc
* Delete SDMX_2-1_SECTION_3A_PART_VII_SAMPLES.doc
* Delete SDMX_2-1_SECTION_3A_PART_VI_REGISTRY.doc
* Delete SDMX_2-1_SECTION_3A_PART_V_QUERY.doc
* Delete SDMX_2-1_SECTION_3A_SDMX_ML.doc
* Add initial draft SDMX 3.0 Section 3A documentation
@dosse
Copy link
Contributor

dosse commented Oct 29, 2021

Hi @sosna, since the generic message type has been deprecated, can we now close this ticket?

@dosse dosse assigned sosna and unassigned DrJMunozMx Oct 29, 2021
@dosse
Copy link
Contributor

dosse commented Nov 29, 2021

Hi @sosna, could we now close this ticket, please?

@agent96
Copy link

agent96 commented Mar 11, 2022

This is either a change to the technical notes on how to generate a schema (allow empty values) - however it would be inconsistent with the behavior of CSV which requires a value.

Alternatively this could be coupled with the ticket on reporting null values:
sdmx-twg/sdmx-csv#27

If a definition was defined in all formats which is the same - then the schema can allow this for attributes in addition to the standard list of allowable content - and the generated schema does not have to be action dependent.

The benefit of using a reserved term for missing is that the user does not need to process the data to discover the action in order to generate the correct schema.

@sosna
Copy link
Member Author

sosna commented Mar 15, 2022

@dosse: Sorry, I just saw your question about closing the ticket now :(.

And I'm not sure I understand the request to close the ticket actually. Yes, the examples use the Generic format, a now deprecated format. But these were just examples and the issue still remains with the other formats?

@dosse dosse assigned dosse and unassigned sosna Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants