ALTER_LOCATION_LABEL
Alters the location label. Use this function to add, change, or remove a location label. You change a location label only if it is not currently in use as part of a storage policy.
You can use this function to remove a location label. However, you cannot remove a location label if the name being removed is used in a storage policy, and the location from which you are removing the label is the last available storage for its associated objects.
Note: If you label an existing storage location that already contains data, and then include the labeled location in one or more storage policies, existing data could be moved. If the ATM determines data stored on a labeled location does not comply with a storage policy, the ATM moves the data elsewhere.
Syntax
ALTER_LOCATION_LABEL ( 'path' , 'node' , 'location_label' )
Parameters
path |
Specifies the path of the storage location. |
node |
The Vertica node for the storage location. If you enter node as an empty string ( |
location_label |
Specifies a storage label as a string, for instance SSD. You can change an existing label assigned to a storage location, or add a new label. Specifying an empty string ('') removes an existing label. |
Privileges
Example
The following example alters (or adds) the label SSD
to the storage location at the given path on all cluster nodes:
=> SELECT alter_location_label('/home/dbadmin/SSD/tables','', 'SSD'); alter_location_label --------------------------------------- /home/dbadmin/SSD/tables label changed. (1 row)