SPARQL the UW

The Wikipedia page for the University of Washington features an InfoBox.

Semantic Web predicates and objects (current as of June 3, 2011) of the University of Washington.

Basic Greasemonkey script

basicSchool.user.js

// ==UserScript==
// @name             XXXXXXXXXXXXXXXXXXXXXXXXXX
// @author           XXXXXXXXXXXXXXXXXXXXXXXXXX
// @date             XXXXXXXXXXXXXXXXXXXXXXXXXX
// @namespace        http://www.ischool.washington.edu/
// @include          *
// @exclude          http://faculty.washington.edu/tabrooks/
// ==/UserScript==


(function()
{
  try {
  
var endpoint;  
var query;

endpoint = "http://dbpedia.org/sparql";

/// RE-ASSEMBLE THE FOLLOWING AS A STRING ON ONE LINE

query = "SELECT ?stuff WHERE { 
{ 
     <http://dbpedia.org/resource/XXXXXXXXXXX>  
     <http://dbpedia.org/property/XXXXXXXXXXX> 
     ?stuff 
} }";

/////////////////////////////////////////////////////////////
// HTTPRequest code
	
GM_xmlhttpRequest({
    method: 'GET',
    url: endpoint + '?query=' + query,
    headers: {
        'User-agent': 'Mozilla/4.0 (compatible) Greasemonkey',
        'Accept': 'text/html',
    },
    onload: function(responseDetails) {			  
			 
						  
			  var myNewXMLDoc = new XML(responseDetails.responseText);
			  		  
			  var newElement = document.createElement("div");
			  
			  newElement.innerHTML = myNewXMLDoc;			  		 

			  //alert(newElement.innerHTML);
			 
			  var i = document.getElementsByTagName("body")[0];
			  i.appendChild(newElement);
	
			  			  	
    }    
    
});


//////////////////////////////////////////////////////////////////
   } catch (eErr) {
      alert ("Greasemonkey error: " + eErr);
   }

   return;

}) ();

What's the mascot of the UW?

query = "SELECT ?stuff WHERE { 
     { 
          <http://dbpedia.org/resource/University_of_Washington>  
          <http://dbpedia.org/property/mascot> 
          ?stuff 
		  
     } }";

What's the motto of the UW?

query = "SELECT ?stuff WHERE { 
     { 
          <http://dbpedia.org/resource/University_of_Washington>  
          <http://dbpedia.org/property/mottoeng> 
          ?stuff 
		  
     } }";

What's the mascot of SPU?

query = "SELECT ?stuff WHERE { 
     { 
        <http://dbpedia.org/resource/Seattle_University>  
        <http://dbpedia.org/property/mascot> 
        ?stuff 
		
     } }";

URIs of Universities and Colleges in Seattle

query = "SELECT ?stuff WHERE { 
      { 
         ?stuff 
         a  
         <http://dbpedia.org/class/yago/UniversitiesAndCollegesInSeattle,Washington>  
      
      } }";
 http://dbpedia.org/resource/Seattle_University
 http://dbpedia.org/resource/Antioch_University
 http://dbpedia.org/resource/Seattle_University
 http://dbpedia.org/resource/Antioch_University
 http://dbpedia.org/resource/Matteo_Ricci_College
 http://dbpedia.org/resource/Gage_Academy_of_Art
 http://dbpedia.org/resource/Seattle_Community_College_District
 http://dbpedia.org/resource/University_of_Washington
 http://dbpedia.org/resource/Seattle_Pacific_University
 http://dbpedia.org/resource/Cornish_College_of_the_Arts
 http://dbpedia.org/resource/Bastyr_University
 http://dbpedia.org/resource/Seattle_Vocational_Institute
 http://dbpedia.org/resource/Seattle_Institute_of_Oriental_Medicine
 http://dbpedia.org/resource/Argosy_University%2FSeattle
 http://dbpedia.org/resource/The_Art_Institute_of_Seattle
 http://dbpedia.org/resource/North_Seattle_Community_College
 http://dbpedia.org/resource/South_Seattle_Community_College
 http://dbpedia.org/resource/Seattle_Central_Community_College
 http://dbpedia.org/resource/Adelphia_College
 http://dbpedia.org/resource/Kepler_College
 http://dbpedia.org/resource/School_of_Visual_Concepts
 

URIs of Universities in State of Washington

query = "SELECT  ?stuff WHERE { 
     { 
        ?stuff 
        a 
        <http://dbpedia.org/class/yago/UniversitiesAndCollegesAccreditedByTheNorthwestCommissionOnCollegesAndUniversities>  
		
     } }";
http://dbpedia.org/resource/Pacific_Lutheran_University
http://dbpedia.org/resource/Eastern_Washington_University
http://dbpedia.org/resource/City_University_of_Seattle
http://dbpedia.org/resource/Henry_Cogswell_College
http://dbpedia.org/resource/Shoreline_Community_College
http://dbpedia.org/resource/Whitworth_University
http://dbpedia.org/resource/Columbia_Basin_College
http://dbpedia.org/resource/Everett_Community_College
http://dbpedia.org/resource/Bates_Technical_College
http://dbpedia.org/resource/Big_Bend_Community_College
http://dbpedia.org/resource/Peninsula_College
http://dbpedia.org/resource/Heritage_University
http://dbpedia.org/resource/Clark_College_(Washington)
http://dbpedia.org/resource/St._Martin's_University
http://dbpedia.org/resource/University_of_Washington
http://dbpedia.org/resource/Western_Washington_University
http://dbpedia.org/resource/The_Evergreen_State_College
http://dbpedia.org/resource/Bellevue_Community_College
http://dbpedia.org/resource/DeVry_University
http://dbpedia.org/resource/Northwest_Indian_College
http://dbpedia.org/resource/Argosy_University
http://dbpedia.org/resource/Faith_Evangelical_Lutheran_Seminary
http://dbpedia.org/resource/Centralia_Community_College
http://dbpedia.org/resource/Highline_Community_College
http://dbpedia.org/resource/South_Puget_Sound_Community_College
http://dbpedia.org/resource/Northwest_University,_USA
http://dbpedia.org/resource/Central_Washington_University
http://dbpedia.org/resource/Walla_Walla_University
http://dbpedia.org/resource/Fairhaven_College
http://dbpedia.org/resource/University_of_Puget_Sound
http://dbpedia.org/resource/DigiPen_Institute_of_Technology
http://dbpedia.org/resource/Clover_Park_Technical_College
http://dbpedia.org/resource/Pierce_College
http://dbpedia.org/resource/Cascadia_Community_College
http://dbpedia.org/resource/Community_Colleges_of_Spokane
http://dbpedia.org/resource/McMillan_Hall
http://dbpedia.org/resource/Eastern_Washington_University_Press
http://dbpedia.org/resource/Edmonds_Community_College
http://dbpedia.org/resource/Kepler_College
http://dbpedia.org/resource/Skagit_Valley_College
http://dbpedia.org/resource/Grays_Harbor_College
http://dbpedia.org/resource/Trinity_Lutheran_College_(Washington)
http://dbpedia.org/resource/Wenatchee_Valley_College
http://dbpedia.org/resource/Gonzaga_University
http://dbpedia.org/resource/Washington_State_University
http://dbpedia.org/resource/Whitman_College
http://dbpedia.org/resource/Tacoma_Community_College
http://dbpedia.org/resource/Green_River_Community_College
http://dbpedia.org/resource/Olympic_College
http://dbpedia.org/resource/Bellingham_Technical_College
http://dbpedia.org/resource/Lake_Washington_Technical_College
http://dbpedia.org/resource/Central_Washington_University-Lynnwood
http://dbpedia.org/resource/Spokane_Falls_Community_College
http://dbpedia.org/resource/Washington_State_University,_Vancouver