Seb35 added a comment.

Related to this task, I’ve created a script to sort the values of P⁠348 (versions of a software), see https://www.wikidata.org/wiki/User:Seb35/sortValues.js (and talk page). It could be adapted for other properties.

But it will be better if it is integrated into Wikibase, perhaps by defining in the property page a specially-recognised property 'Ordering' saying to sort either with the value of the property (with some specially-recognised item) either according to some qualifier either according to the rank. E.g. on Property:P⁠580 we have such property to sort the values of this property directly by the values:

Ordering (PXX) = Value (QYY)

And on Property:P⁠1087 (Elo rating) there could be a property saying to sort by P⁠585 (date):

Ordering (PXX) = Date (P585)

Defining the order in the property page allows the community to discuss what order should be prioritised: e.g. for P⁠1087, should we sort by value or by qualifier "publication date" or by rank? The order defined by the community would be the default order, it could also be created scripts to define alternative orders for specific needs.

On the longer term:

  • it could be added a specially-recognised qualifier to this property to define sub-orders: when two values are identical, the second then the third (etc) order will be used. E.g. sort by P⁠580 (start date) then by P⁠582 (end date),
  • special collations could be added, e.g. for software versions the semantic versioning needs some special attention
  • where should be sorted the special values "no value" and "unknown value"?
  • should we (and how) deal with references? should we allow sorting by (e.g.) P⁠813 publication date from the reference?

PS: in this post, to avoid P⁠348 is intepreted by Phabricator as a link to a paste, and given I didn’t find how to avoid such behaviour in Remarkup syntax help, I used the Unicode character U+2060 (zero-width word joiner) between the P and the number. A bit hacky but it works.


TASK DETAIL
https://phabricator.wikimedia.org/T173432

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Seb35
Cc: Seb35, agray, thiemowmde, Lydia_Pintscher, Bencemac, Sjoerddebruin, Aklapper, Agabi10, Dinadineke, Nandana, tabish.shaikh91, Lahi, Gq86, GoranSMilovanovic, Soteriaspace, Jayprakash12345, JakeTheDeveloper, QZanden, merbst, LawExplorer, Wikidata-bugs, aude, TheDJ, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to