title: Delete node and relationships using cypher query over REST API
body: <p>I'm playing with 2.0 M6 neo4j server (oracle jdk7 on win7 64).</p>
  
  <p>I'm trying to delete a node and its relationships using a single cypher query over the REST API.</p>
  
  <p>The query I create (which works if I run it in the browser UI) looks like:</p>
  
  <pre><code>START n = node( 1916 ) MATCH n-[r]-() DELETE n, r
  </code></pre>
  
  <p>Which by the time I put it through gson comes out as:</p>
  
  <pre><code>{"query":"START n \u003d node( 1916 ) MATCH n-[r]-() DELETE n, r"}
  </code></pre>
  
  <p>Which when sent to the server gets the response:</p>
  
  <pre><code>{
    "columns" : [ ],
    "data" : [ ]
  }
  </code></pre>
  
  <p>My test fails because the node can still be found in neo4j server by its id...</p>
  
  <p>If I simplify my query to just delete a node (that has no relationships) so its:</p>
  
  <pre><code>START n = node( 1920 )  DELETE n
  </code></pre>
  
  <p>Which becomes</p>
  
  <pre><code>{"query":"START n \u003d node( 1920 )  DELETE n"}
  </code></pre>
  
  <p>Then the node is deleted.</p>
  
  <p>Have I missed something?</p>
  
  <p>Thanks, Andy</p>