Matthew Stephens <mattbastard@...> writes:
> 
> 
> Hi Laura:
> 
> I don't see the rest of your query, but I built one and tested it against my 
repo with success:
> 
> PREFIX fedora: <info:fedora/fedora-system:def/relations-external#>
> 
> PREFIX fedora-model: <info:fedora/fedora-system:def/model#>
> SELECT $pid $model  from <#ri> WHERE {
> $pid <fedora-model:hasModel> $model
> }
> 
> That returned what I expected: a list of all objects and their content 
> models. 
 I tried it using the web form (localhost:8080/fedora/risearch), rather than 
pasting it into the browser address bar.  I suspect the problem is you need to 
url encode that string.
> 
> 
> I converted that query and this encoded version works when pasted into the 
address bar of my browser:
> http://localhost:8080/fedora/risearch?
type=tuples&lang=sparql&format=CSV&query=PREFIX%20fedora%3A%20%3Cinfo%3Afedora%2
Ffedora-system%3Adef%2Frelations-external%23%3E%0APREFIX%20fedora-
model%3A%20%3Cinfo%3Afedora%2Ffedora-
system%3Adef%2Fmodel%23%3E%0ASELECT%20%24pid%20%24model%20%20from%20%3C%23ri%3E%
20WHERE%20%7B%0A%24pid%20%3Cfedora-model%3AhasModel%3E%20%24model%0A%7D
> 
> By the way, I don't think you need the prefix statements.  If you look on the 
"Aliases" tab on that web form, you'll see that most common fedora namespaces 
have been aliased for your convenience.
> 
> 
> Best of luck,
> 
> Matthew Stephens
> University of Virginia Library
> 
Thanks a lot Mattew, I pasted you output and it worked on my browser too!
How did you encode your query?


------------------------------------------------------------------------------
Forrester Wave Report - Recovery time is now measured in hours and minutes
not days. Key insights are discussed in the 2010 Forrester Wave Report as
part of an in-depth evaluation of disaster recovery service providers.
Forrester found the best-in-class provider in terms of services and vision.
Read this report now!  http://p.sf.net/sfu/ibm-webcastpromo
_______________________________________________
Fedora-commons-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fedora-commons-developers

Reply via email to