title: How do I get output for a XQuery in MarkLogic in a one line output?
body: <p>Will elaborate -  when I execute the following command :</p>
  <pre><code>let $value := xdmp:forest-status(
                  xdmp:forest-open-replica(
                    xdmp:database-forests(xdmp:database(&quot;Documents&quot;))))
  return $value
  </code></pre>
  <p>Above query returns a lot of information about the database &quot;Documents&quot; forest, like - forest-id, host-id, etc.</p>
  <p>I only require that it should return only the &quot;state&quot; of my forest. How do I do that?</p>