SELECT  Q.n, Q.d, SUM(Q.am)
FROM	sparqltable( SELECT ?n ?am ?d
		  WHERE{ 	?x rdf:type 'Played'.
			?x :amount ?am.
			?x :Do ?y.
			?y rdf:type 'Person'.
		       	?y :name ?n.
			?x :Object ?z.
			?z rdf:type 'Extraction'.
			?z :dataEx ?d.
			
		}
	   )Q
	
GROUP BY Q.n, Q.d
