Retrieving DocumentObjs with Version 0 through ISHRemote


I'm trying to retrieve all the documents in a folder that have a version set to 0. When I call the cmdlet Get-IshFolderContent -IshSession $ishSession -IshFolder $folder it normally ignores all of these documents with version 0.

I tried the following code, but I get the error that the value "0" is invalid for the parameter. 

foreach($folder in $allFolders){
    $objects = Get-IshFolderContent -IshSession $ishSession -VersionFilter "0" -IshFolder $folder

Another approach I tried was to find all DocumentObjs that have their version set to 0; however, this returned no files.

$metadataFilter = Set-IshMetadataFilterField -IshSession $ishSession -Name "VERSION" -Level "Version" -FilterOperator "equal" -Value "0"
$files = Find-IshDocumentObj -IshSession $ishSession -IshTypeFilter ISHModule -MetadataFilter $metadataFilter

Are there any other approaches I could try?

Thank you!

Parents Reply Children
  • Sorry ISHRemote cannot do that. I would guess that at last 4+ major releases of Tridion Docs expect a full logical-version-language to be there to offer a more consistent UX. Just logicals is an outdated idea.

    I wonder which process still creates these version-less logical ids actually

    You can still use the DocumentObj API for that. You could attempt something over $ishSession which offers you a DocumentObj proxy to do a Find or RetrieveMetadata call