Hi Quentin,

Please provide the actually query using the  WITH <graph> DELETE {...} INSERT 
{...} WHERE {...}  syntax for comparison. Also, provide the explain() and 
sparql_to_sql_text()  output of both for comparison ...

Best Regards
Hugh Williams
Professional Services
OpenLink Software, Inc.      //              http://www.openlinksw.com/
Weblog   -- http://www.openlinksw.com/blogs/
LinkedIn -- http://www.linkedin.com/company/openlink-software/
Twitter  -- http://twitter.com/OpenLink
Google+  -- http://plus.google.com/100570109519069333827/
Facebook -- http://www.facebook.com/OpenLinkSoftware
Universal Data Access, Integration, and Management Technology Providers

On 14 Jun 2013, at 02:47, Quentin <[email protected]> wrote:

> I have a problem that I solved but I'm still not sure why it occurred.
> 
> Our application is updating a small number of triples with the below query, 
> constructed in code rather than hand-written.
> 
> delete from graph <http://example.com/datasets/myProject/widgets/1631784244/> 
>  {
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/title> ?o0 .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/xAxisColumn> ?o1 .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/chartType> ?o2 .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/category> ?o3 .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/name> ?o4 .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/chartLevel> ?o5 .
>                               }  where {
> optional { <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/title> ?o0 . }
> optional { <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/xAxisColumn> ?o1 . }
> optional { <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/chartType> ?o2 . }
> optional { <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/category> ?o3 . }
> optional { <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/name> ?o4 . }
> optional { <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/chartLevel> ?o5 . }
> }  
> insert into graph <http://example.com/datasets/myProject/widgets/1631784244/> 
> {
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/title> "Report Name" .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/xAxisColumn> "AxisName" .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/chartType> "column" .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/category> "UserDefinedReports" .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/name> "Report Name" .
> <http://example.com/data/myProject/5163c11f07720918117864> 
> <http://example.com/ontology/sdr/chartLevel> "" .
> }
> 
> When this query is performed in conductor, it times out.  When performed by 
> odbc then it succeeds but takes about 12m40s to execute.
> 
> Refactoring as a WITH <graph> DELETE {...} INSERT {...} WHERE {...} using 
> exactly the same patterns above, it all works in under a second.
> 
> What's the difference there?  Is there an error in the first example that is 
> causing poor behaviour?
> 
> I've looked at the explain plans for the two versions though I find them 
> difficult to interpret.
> -- 
> Quentin | Clear Blue Water Pty Ltd
> [email protected]
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
> 
> Build for Windows Store.
> 
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Virtuoso-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/virtuoso-users

Attachment: smime.p7s
Description: S/MIME cryptographic signature

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Virtuoso-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/virtuoso-users

Reply via email to