[ https://issues.apache.org/jira/browse/MARMOTTA-175?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13617321#comment-13617321 ]
Sebastian Schaffert commented on MARMOTTA-175: ---------------------------------------------- Here is some PostgreSQL EXPLAIN data on GeoNames: NOT IN: Delete on triples (cost=64.25..142972548824713.22 rows=1 width=6) (actual time=12511.678..12511.678 rows=0 loops=1) -> Seq Scan on triples (cost=64.25..142972548824713.22 rows=1 width=6) (actual time=12511.673..12511.673 rows=0 loops=1) Filter: (deleted AND (NOT (hashed SubPlan 1)) AND (NOT (hashed SubPlan 3)) AND (NOT (SubPlan 2))) SubPlan 1 -> Seq Scan on reasoner_just_supp_triples (cost=0.00..27.70 rows=1770 width=8) (never executed) SubPlan 3 -> Seq Scan on versions_removed (cost=0.00..27.70 rows=1770 width=8) (never executed) SubPlan 2 -> Materialize (cost=0.00..2594340.45 rows=105336830 width=8) (never executed) -> Seq Scan on versions_added (cost=0.00..1656184.30 rows=105336830 width=8) (never executed) Total runtime: 12511.745 ms NOT EXISTS: Delete on triples (cost=0.00..5242181.49 rows=1 width=24) (actual time=12465.628..12465.628 rows=0 loops=1) -> Nested Loop Anti Join (cost=0.00..5242181.49 rows=1 width=24) (actual time=12465.627..12465.627 rows=0 loops=1) Join Filter: (versions_removed.triple_id = triples.id) -> Nested Loop Anti Join (cost=0.00..5242118.39 rows=1 width=26) (actual time=12465.626..12465.626 rows=0 loops=1) -> Nested Loop Anti Join (cost=0.00..5242073.50 rows=1 width=20) (actual time=12465.626..12465.626 rows=0 loops=1) Join Filter: (versions_added.triple_id = triples.id) -> Seq Scan on triples (cost=0.00..2269178.82 rows=1 width=14) (actual time=12465.625..12465.625 rows=0 loops=1) Filter: deleted -> Seq Scan on versions_added (cost=0.00..1656184.30 rows=105336830 width=14) (never executed) -> Index Scan using idx_just_supp_triples_triple on reasoner_just_supp_triples (cost=0.00..40.41 rows=9 width=14) (never executed) Index Cond: (triple_id = triples.id) -> Materialize (cost=0.00..36.55 rows=1770 width=14) (never executed) -> Seq Scan on versions_removed (cost=0.00..27.70 rows=1770 width=14) (never executed) Total runtime: 12465.708 ms (14 rows) LEFT JOIN: does not work on PostgreSQL (no LEFT JOIN in a DELETE) > Garbage collection on triple tables > ----------------------------------- > > Key: MARMOTTA-175 > URL: https://issues.apache.org/jira/browse/MARMOTTA-175 > Project: Marmotta > Issue Type: Bug > Components: Triple Store > Affects Versions: 3.1-incubating > Environment: Centos 6.4 64b - JDK 1.6.0_38 - MySql 5.1.67 - Tomcat > 7.0.37 > Reporter: Raffaele Palmieri > Assignee: Sebastian Schaffert > Priority: Minor > Labels: garbage, mysql, triplestore > > During garbage collection of triple tables in log there is the following line: > SQL error while executing garbage collection on triples table: You have an > error in your SQL syntax; check the manual that corresponds to your MySQL > server version for the right syntax to use near 'UNION (SELECT triple_id FROM > reasoner_just_supp_triples WHERE triple_id = triple' at line 1 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira