3,427
edits
Line 2,709: | Line 2,709: | ||
#title:fishing for dates for FSAs | #title:fishing for dates for FSAs | ||
# union query to get [hopefully] every date associated with women FSAs including main dates and qualifier dates, with date precision | # union query to get [hopefully] every date associated with women FSAs including main dates and qualifier dates, with date precision | ||
# updated query for qualifiers | |||
PREFIX bnwd: <https://beyond-notability.wikibase.cloud/entity/> | PREFIX bnwd: <https://beyond-notability.wikibase.cloud/entity/> | ||
Line 2,741: | Line 2,742: | ||
# get dates detail via ?s and psv | # get dates detail via ?s and psv | ||
# gets edtf dates in simplified std wiki date format | # gets edtf dates in simplified std wiki date format. | ||
# https://github.com/ProfessionalWiki/WikibaseEdtf | # https://github.com/ProfessionalWiki/WikibaseEdtf | ||
Line 2,759: | Line 2,760: | ||
?person ?p ?s . | ?person ?p ?s . | ||
# get stuff for ?p . | |||
?prop wikibase:claim ?p; | ?prop wikibase:claim ?p; | ||
wikibase:statementProperty ?ps; | |||
wikibase: | wikibase:statementValue ?psv. | ||
?prop rdfs:label ?prop_label. filter(lang(?prop_label)="en | ?prop rdfs:label ?prop_label. filter(lang(?prop_label)="en") . # spoke at etc | ||
# direct value (usually item) for the property | |||
?s ?ps ?prop_value. | |||
# get date qualifiers. [assumes no edtf in quals. ] | |||
?s ?pq ?date_qual . # | |||
?qual_prop wikibase:qualifier ?pq . | |||
?qual_prop wikibase:propertyType wikibase:Time. | |||
?qual_prop rdfs:label ?date_qual_label . filter(lang(?date_qual_label)="en") . | |||
# qualifier time precision. requires bnpqv: prefix | |||
# pit/start/end/earliest/latest | |||
?s (bnpqv:P1 | bnpqv:P27 | bnpqv:P28 | bnpqv:P51 | bnpqv:P53 ) ?pqv. | |||
?s | #?pqv wikibase:timeValue ?time_qual . #don't need this as well as date_qual. | ||
?pqv wikibase:timePrecision ?date_qual_precision . | |||
} # /qual dates | } # /qual dates | ||
edits