# Trouble creating Wikidata qualifiers from multiline records

**URL:** <https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110>\
**Category:** Support and Helpdesk\
**Tags:** wikidata\
**Created:** [December 10, 2023, 1:06pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110 "2023-12-10T13:06:48Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Susanna\_Anas](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/susanna_anas/32/728_2.png) [@Susanna\_Anas](https://forum.openrefine.org/u/Susanna_Anas)\
**Post date:** [December 10, 2023, 1:06pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/1 "2023-12-10T13:06:48Z")

</div>

I have trouble creating Wikidata imports with multiple qualifiers of the same type when the dataset has multiple rows per record.

The dataset can look like this

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/openrefine/original/1X/aed12aeb86cb84f425118ddb083bc80346e4e702.jpeg)

...

---

<div class="post-metadata">

**Author:** ![Susanna\_Anas](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/susanna_anas/32/728_2.png) [@Susanna\_Anas](https://forum.openrefine.org/u/Susanna_Anas)\
**Post date:** [December 10, 2023, 1:07pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/2 "2023-12-10T13:07:25Z")

</div>

The schema like this

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/openrefine/original/1X/b84147baaed6d395ae5ce50da15b0162bfd183d3.png)

---

<div class="post-metadata">

**Author:** ![Susanna\_Anas](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/susanna_anas/32/728_2.png) [@Susanna\_Anas](https://forum.openrefine.org/u/Susanna_Anas)\
**Post date:** [December 10, 2023, 1:08pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/3 "2023-12-10T13:08:04Z")

</div>

and the desired output like this

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/openrefine/original/1X/6fef0cc406017260732041201f4735d97a6f43be.jpeg)

---

<div class="post-metadata">

**Author:** ![Susanna\_Anas](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/susanna_anas/32/728_2.png) [@Susanna\_Anas](https://forum.openrefine.org/u/Susanna_Anas)\
**Post date:** [December 10, 2023, 1:08pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/4 "2023-12-10T13:08:50Z")

</div>

and this

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/openrefine/original/1X/db839ca7c60e599503ec46790a5945963a50e76a.jpeg)

The one with qualifiers fails to create more than one per item, or creates multiple statements and other variations. The only way I can succeed is to export to QuickStatements for import.

---

<div class="post-metadata">

**Author:** ![antonin\_d](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/antonin_d/32/32_2.png) [@antonin\_d](https://forum.openrefine.org/u/antonin_d)\
**Post date:** [December 10, 2023, 9:35pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/5 "2023-12-10T21:35:31Z")

</div>

Very interesting problem!

What [statement matching settings](https://openrefine.org/docs/manual/wikibase/schema-alignment#matching-strategy) are you using for this statement? You can reach them by clicking on the "configure" button in the schema editor.

Intuitively, if you are using the " **Property and value**" mode, which should be enabled by default, OpenRefine should merge together all the statements you are adding and so that should have the desired effect. But it can well be the matching is only done against existing statements and not between the added ones, which would explain why the statements end up being duplicated. In that case we should create a bug report for that.

Also note that we made some fixes to this statement matching recently, so it's worth using the latest version if you are relying on the specifics of those settings.

---

<div class="post-metadata">

**Author:** ![Susanna\_Anas](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/susanna_anas/32/728_2.png) [@Susanna\_Anas](https://forum.openrefine.org/u/Susanna_Anas)\
**Post date:** [December 16, 2023, 9:21pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/6 "2023-12-16T21:21:36Z")

</div>

I have tried changing them without help. It is of course possible that I have missed some specific configuration, but I have still consistently failed. I will update to the latest version.

---

<div class="post-metadata">

**Author:** ![Antoine2711](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/antoine2711/32/85_2.png) [@Antoine2711](https://forum.openrefine.org/u/Antoine2711)\
**Post date:** [December 17, 2023, 4:36am UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/7 "2023-12-17T04:36:25Z")

</div>

I think this is a real problem. Because a user could want both option, that is having separate values with one qualifier for each, or to combine them in one values, and having many of the same qualifiers (with different values).

I think this come back to defining a tree structure in table data.

Regards, Antoine

---

<div class="post-metadata">

**Author:** ![Eric\_Brunts](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.openrefine.org/eric_brunts/32/994_2.png) [@Eric\_Brunts](https://forum.openrefine.org/u/Eric_Brunts)\
**Post date:** [April 10, 2024, 6:13pm UTC](https://forum.openrefine.org/t/trouble-creating-wikidata-qualifiers-from-multiline-records/1110/8 "2024-04-10T18:13:10Z")

</div>

Hey! We are having the same problem with this, has there been any solution or is this still unsolved?
