Wikidata:WikiProject Properties/Adding missing statements

From Wikidata
Jump to: navigation, search

In a perfect world every property would have properties involved in "Automatically displayed fields" from Template:Property documentation, instance of (P31) and property proposal discussion (P3254) filled.

If you want to help and fill missing properties, you can query them with SPARQL.

Properties with missing instance of (P31) claim[edit]

SELECT ?property ?propertyLabel ?propertyDescription ?propertyType { 
  ?property wikibase:propertyType ?propertyType .
  MINUS { ?property wdt:P31 [] } .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en,en" } .
}

Try it!

Properties with missing subject item of this property (P1629) claim[edit]

SELECT ?property ?propertyLabel ?propertyDescription ?propertyType { 
  ?property wikibase:propertyType ?propertyType .
  MINUS { ?property wdt:P1629 [] } .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en,en" } .
}

Try it!

Properties with missing Wikidata property example (P1855)/Wikidata property example for properties (P2271) claims[edit]

SELECT ?property ?propertyLabel ?propertyDescription ?propertyType { 
  ?property wikibase:propertyType ?propertyType .
  MINUS { ?property (wdt:P1855|wdt:P2271) [] } .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en,en" } .
}

Try it!

Properties with missing property proposal discussion (P3254) claim[edit]

SELECT ?property ?propertyLabel ?propertyDescription ?propertyType { 
  ?property wikibase:propertyType ?propertyType .
  MINUS { ?property wdt:P3254 [] } .
  MINUS { ?property rdf:type wdno:P3254 } .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en,en" } .
}

Try it!

Properties with missing labels and/or descriptions[edit]

Please note: this is an example for German (Q188) language (de). You can put any supported language code into the query.

SELECT ?prop ?label ?description ?datatype {
  BIND( STRLANG( 'x', 'de' ) AS ?dummy ) .
  ?prop wikibase:propertyType ?datatype .
  OPTIONAL {
    ?prop rdfs:label ?label .
    FILTER( LANG( ?label ) = LANG( ?dummy ) ) .
  } .
  OPTIONAL {
    ?prop schema:description ?description .
    FILTER( LANG( ?description ) = LANG( ?dummy ) ) .
  } .
  FILTER( !( BOUND( ?label ) && BOUND( ?description ) ) ) .
}

Try it!