<?xml version="1.0" encoding="UTF-8"?><api:function-page xml:base="/apidoc/8.0/sem.graphDelete.xml" generated="2015-10-07T16:36:00.016766-07:00" mode="javascript" xmlns:api="http://marklogic.com/rundmc/api"><api:function-name>sem.graphDelete</api:function-name><api:suggest>sem.graphdelete</api:suggest><api:suggest>sem</api:suggest><api:suggest>graphdelete</api:suggest><api:function-link mode="xquery" fullname="sem:graph-delete">/apidoc/8.0/sem:graph-delete.xml</api:function-link><api:function mode="javascript" name="graphDelete" lib="sem" category="Semantics" hidden="false" bucket="MarkLogic Built-In Functions" prefix="sem" namespace="http://marklogic.com/semantics" fullname="sem.graphDelete"><api:summary>This function deletes a named graph, and its graph 
	    document containing metadata, from the database. This is an update 
	    function that deletes documents with a root element of 
	    <code xmlns="http://www.w3.org/1999/xhtml">sem:triples</code>.  All other documents are not affected.
    </api:summary><api:params><api:param name="graphname" type="sem:iri"><api:param-description>The name of the graph 
		  to delete.</api:param-description><api:param-name>graphname</api:param-name><api:param-type>sem.iri</api:param-type></api:param></api:params><api:return>null</api:return><api:usage>The default graph document is restored after you use 
  <code xmlns="http://www.w3.org/1999/xhtml">graph-delete</code> to delete graphs.</api:usage><api:example class="javascript"><pre xml:space="preserve" xmlns="http://www.w3.org/1999/xhtml">
declareUpdate();
var sem = require("/MarkLogic/semantics.xqy");
sem.graphDelete(sem.iri("bookgraph")); 
</pre></api:example></api:function></api:function-page>