create_engine()#
#create_engine(name STRING, size STRING[, external_integrations_array ARRAY])
A procedure that creates a new RelationalAI (RAI) engine of the specified size.
An optional array of external access integrations can be enabled on the engine for access to external resources.
Requires the eng_admin application role.
Parameters#
| Name | Type | Description |
|---|---|---|
name | STRING | The name of the new engine (case-sensitive). |
size | STRING | The size of the new engine. This is the same as the host compute pool’s instance family. Must be one of:
|
external_integrations_array | ARRAY | An optional array of external access integrations to enable on the engine. |
Returns#
STRING
Example#
Use the api.create_engine() procedure to create a new RAI engine:
#-- Create a new engine 'my_rai_engine' of size 'HIGHMEM_X64_S'.
CALL relationalai.api.create_engine('my_rai_engine', 'HIGHMEM_X64_S');
/*+----------+
| Success. |
+----------+ */
If an engine with the same name and size already exists, the procedure will return an error.
It is possible to create multiple engines with the same name but different sizes.
By default, engines cannot access external integrations, such as AWS S3 or Azure Blob Storage.
To configure an engine with access to external integrations, pass an array of integration names to the api.create_engine() procedure:
#CALL relationalai.api.create_engine(
'my_rai_engine',
'HIGHMEM_X64_S',
-- Enable existing external integration 'my_external_integration' on the engine.
ARRAY_CONSTRUCT('my_external_integration')
);
/*+----------+
| Success. |
+----------+ */
See Compute Resources for more information on managing engines.