SPARQL Help - Can't get the county for a school
Hi,I am attempting to query for all schools and their county. I cant see any easy way to get the county for a school with sparql because the address property of school doesnt have a county. I am therefore attempting to go via the administrative district to get the county.This query works ok:
prefix sch-ont: <http://education.data.gov.uk/def/school/>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?school ?name ?districtAdministrative WHERE {
?school a sch-ont:School;
sch-ont:establishmentName ?name;
sch-ont:districtAdministrative ?districtAdministrative.
}
ORDER BY ?name
LIMIT 10
But the addition of the county gives me no results:
prefix sch-ont: <http://education.data.gov.uk/def/school/>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?school ?name ?districtAdministrative ?county WHERE {
?school a sch-ont:School;
sch-ont:establishmentName ?name;
sch-ont:districtAdministrative ?districtAdministrative.
?districtAdministrative <http://statistics.data.gov.uk/def/administrative-geography/county> ?county.
}
ORDER BY ?name
LIMIT 10
If anyone could give me some pointers to why the second query doesnt return anything it would be much appreciated.
Hi,
It looks as though the data for the county information is behind a different SPARQL endpoint, http://services.data.gov.uk/statistics/sparql, so you'd have to join the data some other way.
I don't think the endpoints currently support the upcoming SERVICE method for basic federated queries (see http://www.w3.org/TR/sparql-features/#Basic_federated_query and http://www.snee.com/bobdc.blog/2010/01/federated-sparql-queries.html) and the www.sparql.org server seems to be down, so you may have to do the join manually, i.e. by getting back your list of ?districtAdministrative resources and iterating over them to create queries to the statistics SPARQL endpoint.
Cheers,Alex.
cuu du lieu
- SEO
Dich vu SEO
Cong ty SEO
Web hosting
tu van SEO
Phan tich SEO
Giai phap SEO
Lam SEO
Phan mem SEO
Thiet ke web
Ten mien
SEo la gi
Thiet ke website gia re
Thiet ke web noi that
Thiet ke web du lich
thiet ke website tin tuc
Thiet ke website ban hang
Thiet ke website gioi thieu cong ty
Thiet ke website bat dong san
Thiet ke website chuyen nghiep
Thiet ke web thuong mai dien tu
Quang cao facebook
cuu du lieu
Ghế văn phòng
Ghế giám đốc
- vi tinh cu
- cuu du lieu
- SEO corporation
- Dich vu sua nha
- Thanh ly cong ty
- vi tinh cu gia re
- cuu du lieu
- may tinh cu gia re
- tu van dau tu
- tu van thanh lap cong ty
- thanh lap cong ty 100 von nuoc ngoai
- Free auto backlink
- anime
- Đẹp
- Dịch vụ bảo vệ
- Dịch vụ cầm đồ
- Dịch vụ sửa nhà
- Dịch vụ dọn nhà
- Dịch vụ visa
- Điện Thoại
- Điện thoại giá rẻ
- english songs
- Gái đẹp
- Ghế văn phòng
- Giới tính
- Thu mua vi tính
- Ipad
- Iphone
- iphone giá rẻ
- ipod giá rẻ
- japanese girls
- Japan girls
- korean girl
- Làm đẹp
- Laptop giá rẻ
- maxim girls
- Máy tính bảng
- Nhạc vàng
- Nội thất
- Phục hồi dữ liệu
- thailand girl
- thailand songs
- Thanh lý công ty
- Thanh lý máy tính
- Thanh lý phòng net
- tom and jerry
- Trần thạch cao
- vách thạch cao
- Vietnam girls
- Vi tính củ
- Gái đẹp
- Làm đẹp