Hi,

once again I don't have your initial data so I'm using my fixed
version of the rdfunload.xml file you gave me earlier. I'm using your
example (MyTest.java) and enabling the line which calls the "insert"
method (before the call to the "get" method).

When I do the query (note: Replaced "Paris" with "outside" since the
rdfunload.xml data doesn't contain "Paris"):
PREFIX ore:<http://www.openarchives.org/ore/terms/>
PREFIX rdf:<http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX orex:<http://library.lanl.gov/orex/terms/>
PREFIX dc:<http://purl.org/dc/elements/1.1/>
SELECT ?photo ?i
WHERE {
   ?s ?p  "outside"  .
   ?photo  ?x  ?s  .
   ?photo  ?y  "photo"  .
}

I get the result:
photo:http://localhost:8080/neofl/ore/photo/376830691

When i do the query:
PREFIX ore:<http://www.openarchives.org/ore/terms/>
PREFIX rdf:<http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX orex:<http://library.lanl.gov/orex/terms/>
PREFIX dc:<http://purl.org/dc/elements/1.1/>
SELECT ?photo ?i
WHERE {
   ?s ?p  "outside"  .
   ?photo  ?x  ?s  .
   ?photo  ?y  "photo"  .
   ?photo  ore:aggregates  ?i .
}

I get the result:
image:http://www.flickr.com/photos/10ch/376830691/sizes/o/
photo:http://localhost:8080/neofl/ore/photo/376830691
image:http://www.flickr.com/photos/10ch/376830691/sizes/l/
photo:http://localhost:8080/neofl/ore/photo/376830691
image:http://www.flickr.com/photos/10ch/376830691/sizes/m/
photo:http://localhost:8080/neofl/ore/photo/376830691
image:http://www.flickr.com/photos/10ch/376830691/sizes/s/
photo:http://localhost:8080/neofl/ore/photo/376830691
image:http://www.flickr.com/photos/10ch/376830691/sizes/t/
photo:http://localhost:8080/neofl/ore/photo/376830691
image:http://www.flickr.com/photos/10ch/376830691/sizes/sq/
photo:http://localhost:8080/neofl/ore/photo/376830691

So things are working for me here, but not for you with the exact same
code? Weird. Perhaps you have a different data set than me?

Best,
Mattias

2009/2/19 Lyudmila L. Balakireva <lu...@lanl.gov>:
> thank you for your replay, I attached my test classes. May be you can spot
> the difference in approach.
> Luda
>>
>>>X-Sieve: CMU Sieve 2.2
>>>X-NIE-2-Virus-Scanner: amavisd-new at mailrelay1.lanl.gov
>>>Date: Thu, 19 Feb 2009 09:52:31 +0100
>>>Subject: Re: re :VerboseQuadStore
>>>From: Mattias Persson <matt...@neotechnology.com>
>>>To: lu...@lanl.gov
>>>Cc: Neo4j user discussions <user@lists.neo4j.org>
>>>X-Proofpoint-Virus-Version: vendor=fsecure
>>>engine=1.12.7400:2.4.4,1.2.40,4.0.166
>>>definitions=2009-02-19_02:2009-02-10,2009-02-19,2009-02-19 signatures=0
>>>X-Proofpoint-Spam: 0
>>>X-NIE-2-MailScanner-Information: Please see
>>>http://network.lanl.gov/email/virus-scan.php
>>>X-NIE-2-MailScanner: Found to be clean
>>>X-NIE-2-MailScanner-From: matt...@neopersistence.com
>>>X-Spam-Status: No
>>>
>>>I converted the xml file into decent format (see attached file) and
>>>ran the example. Once again I get answers when running that query.
>>>
>>>PREFIX ore:<http://www.openarchives.org/ore/terms/>
>>>PREFIX rdf:<http://www.w3.org/1999/02/22-rdf-syntax-ns#>
>>>PREFIX orex:<http://library.lanl.gov/orex/terms/>
>>>PREFIX dc:<http://purl.org/dc/elements/1.1/>
>>>SELECT ?photo
>>>WHERE
>>>{
>>>    ?s ?p  "outside"  .
>>>    ?photo  ?x  ?s  .
>>>    ?photo  ?y  "photo" .
>>>    ?photo ore:aggregates  ?i .
>>>}
>>>
>>>I get 6 results back from that query.
>>>
>>>There surely must something we do differently, but I don't know what.
>>>
>>>Best,
>>>Mattias
>>>
>>>2009/2/18 Mattias Persson <matt...@neotechnology.com>:
>>> > I'm guessing that's a problem in the exporter and not in the neo rdf
>>> > library... but I'm not sure.
>>> >
>>> > Anyway, would it be possible for you to send me your original data so
>>> > that I can test with it, making my tests exactely like yours?
>>> >
>>> > Best,
>>> > Mattias
>>> >
>>> > 2009/2/17 Lyudmila L. Balakireva <lu...@lanl.gov>:
>>> >> Hi,
>>> >> actually I had rdf in the form as you mentioned. But when you
>>> serialize
>>> >> rdf from neo it's outputs it in this form. (rc.export(
>>> >> rdfxmlWriter,context);
>>> >> Luda
>>> >>
>>> >>> Hi again Lyudmila.
>>> >>>
>>> >>> I may have found the source of the problem. I see that when
>>> importing
>>> >>> from your rdf/xml file the predicates in the statements aren't
>>> stored
>>> >>> in the sail as the full URIs, but as short versions, f.ex
>>> >>> "orex:value".
>>> >>>
>>> >>> Then I look at the rdfunload.xml file and see some weird things,
>>> f.ex:
>>> >>>
>>> >>>     <value xmlns="orex:">outside</value>
>>> >>>
>>> >>> Now that's a syntax I've never seen before and all values in the
>>> file
>>> >>> are like that. I tried to change the tags so that they look
>>> something
>>> >>> like:
>>> >>>
>>> >>>     <orex:value>outside</orex:value>
>>> >>>
>>> >>> And it all worked much better. Isn't that how it's supposed to look
>>> >>> like? At least that's how I've learned to write rdf/xml and it makes
>>> >>> more sense to me. I think this will make it work for you.
>>> >>>
>>> >>> Another thing, performance: If you see that the performance isn't
>>> good
>>> >>> enough using an external sparql analyzer like this you could try
>>> using
>>> >>> our own sparql engine which talks to neo directly with a little help
>>> >>> from the neo-rdf layer. I'll see if I can write a piece of code
>>> which
>>> >>> would get you up and running using that too.
>>> >>>
>>> >>> Best,
>>> >>> Mattias
>>> >>>
>>> >>> 2009/2/13 Lyudmila L. Balakireva <lu...@lanl.gov>:
>>> >>>> hi, Mattias
>>> >>>>
>>> >>>> I am attaching rdf sample I was testing .
>>> >>>> I was loading rdf with specific context.
>>> >>>>
>>> >>>> RepositoryConnection rc = repo.getConnection();
>>> >>>>                        ValueFactory f = repo.getValueFactory();
>>> >>>>                        for ( File file : files )
>>> >>>>                        {
>>> >>>>
>>> >>>>
>>> >>>>                           // URI context =
>>> >>>> f.createURI("http://localhost:8080/neofl/ore/photo/2926368578";);
>>> >>>>                            URI context =
>>> >>>>
>>> f.createURI("http://localhost:8080/neofl/ore/photo/1437207680/2009-01-13T19:21:23";);
>>> >>>>
>>> >>>>                           rc.add( file, "",
>>> RDFFormat.RDFXML,context);
>>> >>>>                          //  rc.add( file, "", RDFFormat.RDFXML);
>>> >>>>
>>> >>>>                        }
>>> >>>>
>>> >>>>
>>> >>>> Thank you,
>>> >>>>
>>> >>>>
>>> >>>> Lyudmila Balalkireva
>>> >>>> lu...@lanl.gov
>>> >>>
>>> >>>
>>> >>>
>>> >>> --
>>> >>> Mattias Persson, [matt...@neotechnology.com]
>>> >>> Neo Technology, www.neotechnology.com
>>> >>>
>>> >>
>>> >>
>>> >
>>> >
>>> >
>>> > --
>>> > Mattias Persson, [matt...@neotechnology.com]
>>> > Neo Technology, www.neotechnology.com
>>> >
>>>
>>>
>>>
>>>--
>>>Mattias Persson, [matt...@neotechnology.com]
>>>Neo Technology, www.neotechnology.com
>>>
>>>Content-Type: text/xml; charset=US-ASCII; name="rdfunload.xml"
>>>Content-Disposition: attachment; filename="rdfunload.xml"
>>>X-Attachment-Id: f_frd6zr5j0
>>
>



-- 
Mattias Persson, [matt...@neotechnology.com]
Neo Technology, www.neotechnology.com
_______________________________________________
Neo mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user

Reply via email to