NIH | National Cancer Institute | NCI Wiki  

WIKI MAINTENANCE NOTICE

Please be advised that NCI Wiki will be will be undergoing maintenance on Monday, June 24th between 1000 ET and 1100 ET.
Wiki will remain available, but users may experience screen refreshes or HTTP 502 errors during the maintenance period. If you encounter these errors, wait 1-2 minutes, then refresh your page.

If you have any questions or concerns, please contact the CBIIT Atlassian Management Team.

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Deleted based on 1/19 discussion.
Excerpt
hiddentrue

dm_get_dataobject

Note

This page is a work in progress.

The following command gets all metadata associated with a data file:

If your user account has the Read permission level on a data file in DME, the following command allows you to retrieve all metadata associated with that data file:

code
Panel
borderColorsilver
borderStylesolid
Clipboard
AllowLineWraptrue

dm_get_dataobject

[optional parameters] <dataobject-path>

[metadata-file] [REST-response]


The following table describes each parameter:

ParameterDescription
<dataobject-path> 
The path to the data file.
[-h]If you want to print a usage (help) message for this command, specify this option.
[-a <attribute name>]An optional parameter, specifying an attribute to obtain the value of that attribute.
[-D <REST-response>]

An optional parameter, specifying a path and filename in your local system. The system always creates a response file:

[metadata-file]
An optional path and filename.

  • If you specify this parameter, the system
creates
  • saves the response from the server to the specified file in the specified location
and saves the metadata in that file
  • .
  • If you
do not specify
  • omit this parameter, the system
prints the metadata to standard output
  • saves the file as get-item-response-header.tmp in your home directory.
[
REST
-o <metadata-
response
file>]

An optional parameter, specifying a path and filename in your local system. The system always creates a metadata file:

  • If you specify this parameter, the system
creates
  • saves the metadata to the specified file in the specified location.
  • If you omit this parameter, the system prints the metadata to standard output and saves the
response header (response from the server) in that file.
  • If you do not specify this parameter, (TBD)
    • file as get-item-response-message.json.tmp in your home directory.

    The metadata includes information about the data file, a list of attribute values for the file, and a list of attribute values for the parent collection.

    <dataobject-path> 
    The path to the data file in DME.

    For example, the following command allows you to view the metadata associated with the sample.txt data file:

    Panel
    borderColorsilver
    borderStylesolid
    Clipboard
    AllowLineWraptrue

    dm_get_dataobject /Example_Archive/PI_Lab1/Project_Orig/sample.txt


    The basic format of the command output is as follows:

    Code Block
    {
        "dataObjects": [
            {
                "dataObject": {...},
                "metadataEntries": {
                    "parentMetadataEntries": [...],
                    "selfMetadataEntries": [...]
                }
            }
        ]
    }

    In this format, the "dataObject" and "selfMetadataEntries" elements provide information about the file you specified, while the "parentMetadataEntries" element provides information about the collection that contains the file you specifiedFor instructions on performing the same task in the GUI, refer to Viewing Data Details via the GUI