query-bdbd94d776799e2532523e1a3726ef4b

rq turtle/ttl

Marinha ultimo novembro

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX pr: <http://www.wikidata.org/prop/reference/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT  distinct ?item  ?itemLabel ?lenght ?refURL #?serv ?manufLabel ?criadoLabel ?countryLabel # ?localLabel  # ?foto # ?instLabel ?powered ?serv # ?foto # ?instLabel ?lenght # ?draft ?beam  ?serv  ?refurl  ?evento  ?eventoLabel 
# ?operatorLabel ?propriLabel ?itemDescription
# ?foto # ?instLabel ?itemDescription   # ?foto  # ?itemAltLabel # ?servret  ?pennant ?differ ?instLabel
# ?operatorLabel ?topic ?classLabel   ?foto    # ?mass ?serv 
# ?countryLabel  ?manufLabel ?manuf  ?incep  ?catshipname ?imo  ?manuf  
# ?vesselLabel  ?namedLabel ?subclaLabel ?vesselLabel 
# ?itemDescription ?itemAltLabel
WHERE 
{

            { ?item wdt:P31 ?inst .                 }    #  instance  -  tipo de navio
           { ?item wdt:P31/wdt:P279* wd:Q1229765 . }    #  instancia -  watercraft e subclasses
 # UNION 
  #          { ?item wdt:P31/wdt:P279* wd:Q559026 .  }    #  instancia -  ship class

          { ?item wdt:P137 ?navy .             }    # operator ?navi
          { ?item wdt:P137 wd:Q588089 .        }    # operator portuguese navy   
#novo
 # ?item wdt:P2043  ?lenght . 
 # ?item p:P2043 [ prov:wasDerivedFrom [ pr:P958 ?refURL ] ] .
#novo fim

 #ver daqui
 #      { ?item wdt:P495/wdt:P361* wd:Q200464 .  }  #  pais origem - imperio portugues
 #      { ?item wdt:P495/wdt:P361* wd:Q148 .  }  #  pais origem - imperio portugues  
 # ate aqui 

  # { ?item wdt:P31 wd:Q5258439 .           }  # inst - galeota real
  # { ?item wdt:P516   wd:Q25999 .          }  # powered by sail
  # { ?item wdt:P31/wdt:P279*  wd:Q559026 . } 
  # FILTER NOT EXISTS  { ?item wdt:P373   ?comcat .            }  # comons cat
  # FILTER NOT EXISTS  { ?item wdt:P186   ?made .              }  # made from material 
  # FILTER NOT EXISTS  { ?item wdt:P31/wdt:P279*  wd:Q559026 . } 
  # FILTER NOT EXISTS  { ?item   wdt:P176   ?manuf  .          }  #numero vessel class

# filter not exists { ?item wdt:P31 wd:Q12859788 . }
#  { ?item wdt:P31 wd:Q214196. }  #canhoneira


#caracte ----------------------------------------------------------------------
#  OPTIONAL          {    ?item wdt:P516   ?powered .     }    # 1 powered by - motores
#  optional          {    ?item wdt:P2067  ?mass .        }    # 2 mass
  OPTIONAL          {    ?item wdt:P2043  ?lenght .      }    # 31 length  comprimento
#  OPTIONAL          {    ?item wdt:P2261  ?beam .        }    # 32 beam boca
#  OPTIONAL          {    ?item wdt:P2262  ?draft .       }    # 33 draft  calado
#  OPTIONAL          {    ?item wdt:P4511  ?pontal .      }    # 34 vertical depth - (ver PetScan) pontal (P2048)
#  Optional          {    ?item wdt:P1083  ?guarn .       }    # 4 capacidade maxima - guarniçao
#  Optional         {    ?item wdt:P520   ?armament .    }    # 5 armamento (ver PetScan) Q1330003 torpedo tube
#  OPTIONAL          {    ?item wdt:P2052  ?speed .       }    # 6 speed
#fim caracte ----------------------------------------------------------------------

 OPTIONAL {    ?item wdt:P7782  ?catshipname . }    # operator portuguese navy
 OPTIONAL {    ?item wdt:P289   ?class  .      }    # numero vessel class 
 OPTIONAL {    ?item wdt:P607   ?conflit  .    }    # numero conflit war 
 OPTIONAL {    ?item wdt:P373   ?commonscat .  }    # operator portuguese navy
 OPTIONAL {    ?item wdt:P495   ?country  .    }    # numero vessel clas 
 OPTIONAL {    ?item wdt:P1071  ?criado  .     }    # criado em
 OPTIONAL {    ?item wdt:P1889  ?differ  .     }    # different
 OPTIONAL {    ?item wdt:P793   ?evento  .     }    # evento
  OPTIONAL {    ?item wdt:P18    ?foto  .       }    # foto
 OPTIONAL {    ?item wdt:P458   ?imo .         }    # operator portuguese navy
 OPTIONAL {    ?item wdt:P571   ?incep  .      }    # numero vessel class 
 OPTIONAL {    ?item wdt:P1071  ?local  .      }    # location of cration
 OPTIONAL   {    ?item wdt:P176   ?manuf  .      }    # numero vessel class
 OPTIONAL {    ?item wdt:P138   ?named  .      }    # numero vessel class 
 OPTIONAL {    ?item wdt:P137   ?operator  .   }    # numero amura 
 OPTIONAL {    ?item wdt:P495   ?paisori  .    }    # pais de origem
# OPTIONAL {    ?item wdt:P879   ?pennant  .    }    # numero amura 
# OPTIONAL {    ?item wdt:P127   ?propri .      }    # proprietario owned b
 OPTIONAL {    ?item wdt:P973   ?refurl .      }    # proprietario referencia URL
 OPTIONAL {    ?item wdt:P729   ?serv .        }    # operator portuguese navy
# OPTIONAL {    ?item wdt:P730   ?servret .     }    # operator portuguese navy
# OPTIONAL {    ?item wdt:P1813  ?short  .      }    # short
 # OPTIONAL {    ?item wdt:P279   ?subcla .      }    # numero subcal 
 # OPTIONAL {    ?item wdt:P910   ?topic .       }    # topico

#  OPTIONAL {?comm schema:about ?item ; schema:isPartOf <https://commons.wikimedia.org/> .}

  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } # Helps get the label in your language,
  #defaultView:Map if not, then en language

#  ?article2 schema:about ?manuf . 
#  ?article2 schema:isPartOf <https://commons.wikimedia.org/> . #Commons

#FILTER(NOT EXISTS {
#    ?item schema:description ?itemdesc.
#    FILTER(LANG(?itemdesc) = "pt")
#  })

#  ?article1 schema:about ?item . 
#  ?article1 schema:isPartOf <https://pt.wikipedia.org/> .   #WP.en
}
ORDER BY ?serv
LIMIT 700

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v6("?catshipname") v7("?class") v9("?commonscat") v8("?conflit") v10("?country") v11("?criado") v12("?differ") v13("?evento") v14("?foto") v15("?imo") v16("?incep") v3("?inst") v2("?item"):::projected v5("?lenght"):::projected v17("?local") v18("?manuf") v19("?named") v4("?navy") v20("?operator") v21("?paisori") v22("?refurl") v1("?serv") a1((" ")) c23(["bd:serviceParam"]):::iri c5(["wd:Q588089"]):::iri c3(["wd:Q1229765"]):::iri c25(["#91;AUTO_LANGUAGE#93;,en"]):::literal v2 --"p:direct/P31"--> v3 v2 --"p:direct/P31"--> a1 a1 --"p:direct/P279"--> c3 v2 --"p:direct/P137"--> v4 v2 --"p:direct/P137"--> c5 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P2043".-> v5 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P7782".-> v6 end subgraph optional2["(optional)"] style optional2 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P289".-> v7 end subgraph optional3["(optional)"] style optional3 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P607".-> v8 end subgraph optional4["(optional)"] style optional4 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P373".-> v9 end subgraph optional5["(optional)"] style optional5 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P495".-> v10 end subgraph optional6["(optional)"] style optional6 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P1071".-> v11 end subgraph optional7["(optional)"] style optional7 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P1889".-> v12 end subgraph optional8["(optional)"] style optional8 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P793".-> v13 end subgraph optional9["(optional)"] style optional9 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P18".-> v14 end subgraph optional10["(optional)"] style optional10 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P458".-> v15 end subgraph optional11["(optional)"] style optional11 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P571".-> v16 end subgraph optional12["(optional)"] style optional12 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P1071".-> v17 end subgraph optional13["(optional)"] style optional13 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P176".-> v18 end subgraph optional14["(optional)"] style optional14 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P138".-> v19 end subgraph optional15["(optional)"] style optional15 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P137".-> v20 end subgraph optional16["(optional)"] style optional16 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P495".-> v21 end subgraph optional17["(optional)"] style optional17 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P973".-> v22 end subgraph optional18["(optional)"] style optional18 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:direct/P729".-> v1 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c23 --"wikibase:language"--> c25 end