ALTER LIBRARY

Replaces the library file (for example, C++ .so file or Java .jar file) associated with a UDx library that is defined in the Vertica catalog. Vertica automatically distributes copies of the updated file throughout the cluster. UDxs defined in the catalog that reference the updated library automatically start using the updated library file. Nodes that are down or added to the cluster also receive a copy of the updated library file as soon as they join the cluster.

Syntax

ALTER LIBRARY [[database.]schema.]library‑name  [DEPENDS 'support‑path'] AS 'library‑path';

Parameters

schema

Specifies a schema, by default public. If schema is any schema other than public, you must supply the schema name. For example:

myschema.thisDbObject

If you specify a database, it must be the current database.

library‑name

The library to alter. You can only alter an existing library.

DEPENDS 'support‑path'

Indicates that the UDx library depends on one or more support libraries, where support‑path specifies one or more absolute paths to the support libraries files, located in the initiator node's file system.

You can specify multiple support paths as follows:

  • Separate multiple paths with colons (:).
  • Specify a directory that contains multiple libraries with an asterisk wildcard (*). For example: /home/mydir/mylibs/*
library‑path

The absolute path in the initiator node file system to the replacement library file.

Privileges

Superuser

Requirements

Examples

This example shows how to update an already-defined library myFunctions with a new file.

=> ALTER LIBRARY myFunctions AS '/home/dbadmin/my_new_functions.so';

See Also

Developing User-Defined Extensions (UDxs)