Objective
It allows to unlink the content of a folder (both documents and subfolders). This method also controls the order of the non-deleted children into FOLDER_ITEM table. This method doesn’t delete documents, it only deletes the references to the parent folder. It is important to know how the FOLDER_ITEM DM table manages document versions with the “version” and “version_type” fields. The “version_type” field can be populated with values “specific” or “most recent version”. That means that to delete a “specific” version of a document, it is necessary to pass to the method the “specific” value of the version or the subversion to be deleted. To delete the “most recent version” then only the document number must be passed.
Then, if there are different versions of the same document in a folder, the method will have to be called at least 2 times to delete all the content in the folder. DST must be provided.
Parameters
Parameter | Description | Type |
library | eDOCS library | String |
user | User name | String |
password | User password | String |
dbSchema | Database schema. By default is set to “DOCSADM” if an empty string is passed. | String |
childFolder | Document number of the child document or folder to be deleted. | String |
version | Version number of the document. (1, 2, 3 …). | String |
subVersion | Subversion letter (A, B, C, …). No letter will be used by default. | String |
parentFolder | Document number of the parent folder. | String |
client | Optional parameter for the client code | String |
project | Optional parameter for the project code | String |
Rest Invoke
- http://localhost:port/GSService/xml/ or http://localhost:port/GSService/json/
- UriTemplate:
- “/ParentChildFolderRelationRemove/?library={library}&user={user}&password={password}&dbSchema={dbSchema}&childFolder={childFolder}&version={version}&subVersion={subVersion}&parentFolder={parentFolder}&client={client}&project={project}”
- “/ParentChildFolderRelationRemoveDST/?library={library}&user={user}&dst={dst}&dbSchema={dbSchema}&childFolder={childFolder}&version={version}&subVersion={subVersion}&parentFolder={parentFolder}&client={client}&project={project}”
Example
http://localhost:8732/GSService/xml/ParentChildFolderRelationRemove/?library=DMTESTLEGAL&user=admin&password=owc123&dbSchema=DOCSADM&childFolder=453&version=1&subVersion=!&parentFolder=14
The method returns 0 if the reference has been properly removed.
DST Example
http://localhost:8732/GSService/xml/ParentChildFolderRelationRemoveDST/?library=DMTESTLEGAL&user=admin&dst=afd448a5d0f9b...55355b8c677ad16&dbSchema=DOCSADM&childFolder=453&version=1&subVersion=!&parentFolder=14
Error
The method returns -1 if the content has not been found or cannot be removed.