<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How can I retrieve all or specific version of a particular document? in Nuxeo Forum</title>
    <link>https://connect.hyland.com/t5/nuxeo-forum/how-can-i-retrieve-all-or-specific-version-of-a-particular/m-p/321145#M8146</link>
    <description>&lt;P&gt;using a &lt;CODE&gt;Context.RunScript&lt;/CODE&gt; operation quickly comes to my mind. I'm not sure if it's "the way" but something in those lines should work to get versions of the current doc.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;  &amp;lt;operation id="Context.RunScript"&amp;gt;
    &amp;lt;param name="script" type="string"&amp;gt;
      versions = Document.getSession().getVersions(Document.getDoc().getRef());
      Context.put("list_of_versions", versions);
    &amp;lt;/param&amp;gt;
  &amp;lt;/operation&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;then you would access in further operations using the &lt;CODE&gt;&amp;lt;param ...&amp;gt;expr:@{list_of_versions}&amp;lt;/param&amp;gt;&lt;/CODE&gt; syntax. There is also the getDocumentWithVersion() method on CoreSession if you know which version you want.&lt;/P&gt;</description>
    <pubDate>Thu, 09 Aug 2012 23:30:02 GMT</pubDate>
    <dc:creator>simpoir_</dc:creator>
    <dc:date>2012-08-09T23:30:02Z</dc:date>
    <item>
      <title>How can I retrieve all or specific version of a particular document?</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/how-can-i-retrieve-all-or-specific-version-of-a-particular/m-p/321144#M8145</link>
      <description>&lt;P&gt;I am using nuxeo automation client API to retrieve the list of documents. Document.Query always return the latest version of the document.&lt;/P&gt;
&lt;P&gt;How can I retrieve all or specific version of a particular document?&lt;/P&gt;</description>
      <pubDate>Wed, 08 Aug 2012 10:45:38 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/how-can-i-retrieve-all-or-specific-version-of-a-particular/m-p/321144#M8145</guid>
      <dc:creator>eric_</dc:creator>
      <dc:date>2012-08-08T10:45:38Z</dc:date>
    </item>
    <item>
      <title>Re: How can I retrieve all or specific version of a particular document?</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/how-can-i-retrieve-all-or-specific-version-of-a-particular/m-p/321145#M8146</link>
      <description>&lt;P&gt;using a &lt;CODE&gt;Context.RunScript&lt;/CODE&gt; operation quickly comes to my mind. I'm not sure if it's "the way" but something in those lines should work to get versions of the current doc.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;  &amp;lt;operation id="Context.RunScript"&amp;gt;
    &amp;lt;param name="script" type="string"&amp;gt;
      versions = Document.getSession().getVersions(Document.getDoc().getRef());
      Context.put("list_of_versions", versions);
    &amp;lt;/param&amp;gt;
  &amp;lt;/operation&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;then you would access in further operations using the &lt;CODE&gt;&amp;lt;param ...&amp;gt;expr:@{list_of_versions}&amp;lt;/param&amp;gt;&lt;/CODE&gt; syntax. There is also the getDocumentWithVersion() method on CoreSession if you know which version you want.&lt;/P&gt;</description>
      <pubDate>Thu, 09 Aug 2012 23:30:02 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/how-can-i-retrieve-all-or-specific-version-of-a-particular/m-p/321145#M8146</guid>
      <dc:creator>simpoir_</dc:creator>
      <dc:date>2012-08-09T23:30:02Z</dc:date>
    </item>
  </channel>
</rss>

