HP StoreAll Storage User Manual
Page 188

This example queries all files in the lab/images subdirectory of the ibrix_share1 HTTP share,
in addition to the files in all subdirectories, recursively walking the directory tree. A JSON document
is returned containing the system size value and the custom metadata value for the physician
key, for all files and subdirectories in the lab/images directory tree, as well as for the lab/
images
directory itself. The list of files is ordered alphabetically by file name.
Get selected metadata for a page of files in a given directory tree
The following is one command line:
curl -g "http://99.226.50.92/ibrix_share1/lab/images/?attributes=
system::size,physician&recurse&skip=2000&top=100"
This example queries all files in the lab/images subdirectory of the ibrix_share1 HTTP share,
in addition to the files in all subdirectories, recursively walking the directory tree. A JSON document
is returned containing the system size value and the custom metadata value for the physician
key, for result set entries 2001 through 2100. The results are not ordered, which speeds up the
query. In a typical scenario, such as in the example mentioned in this section, the client has already
issued queries to receive the first 2000 results. The client usually issues further queries until no more
results are returned.
Get selected metadata for all files in a given directory tree that matches a system metadata query
The following is one command line:
curl -g "http://99.226.50.92/ibrix_share1/lab/images/?attributes=
system::size,physician&query=system::size>2048&recurse"
This example queries all files larger than 2 KB in the lab/images subdirectory of the
ibrix_share1
HTTP share, as well as all files in all subdirectories, recursively walking the
directory tree. A JSON document is returned containing the system size value and the custom
metadata value for the physician attribute, for all >2KB files and subdirectories in the lab/
images
directory tree, as well as for the lab/imagesdirectory itself (if >2KB).
Get selected metadata for all files in a given directory tree that matches a custom metadata query
The following is one command line:
curl -g "http://99.226.50.92/ibrix_share1/lab/images/?attributes=
system::size,physician&query=department!='billing'&recurse"
This example queries all files that do not have a custom metadata attribute of department with
a value other than billing, in the lab/images subdirectory of the ibrix_share1 HTTP share,
in addition to the files in all subdirectories, recursively walking the directory tree. A JSON document
is returned containing the system size value and the custom metadata value for the physician
attribute
, for all files and subdirectories not in the billing department in the lab/images
directory tree. Files without a department attribute are not included in the results.
Get all metadata for all files in a given directory tree that matches a custom metadata query
The following is one command line:
curl -g "http://99.226.50.92/ibrix_share1/lab/images/?attributes=
*&query=physician~'^S.*'&recurse"
This example queries all files that have a custom metadata attribute of physician with a value
that starts with S in the lab/images subdirectory of the ibrix_share1 HTTP share, in addition
to the files in all subdirectories, recursively walking the directory tree. A JSON document is returned
containing all attribute values, for all files and subdirectories in the lab/images directory tree
that matches the custom metadata criterion.
Get all custom metadata for all files in a given directory tree that matches a custom metadata query
The following is one command line:
188 Express Query