Transform¶
Defines a transform, which converts a data type to and from the form a procedural language uses. A transform has no owner. The project keeps it in the schema of its data type. When the data type is built-in, the project keeps it in the first schema that its functions name, or in public.
Properties¶
| Property | Type | Required | Description |
|---|---|---|---|
schema |
string |
— | Schema. |
type |
string |
yes | The data type the transform converts. |
language |
string |
yes | The procedural language the transform is for. |
from_sql |
string |
— | The function, with its argument types, that converts the data type to the form the language uses. It takes one argument of type internal and returns internal. |
to_sql |
string |
— | The function, with its argument types, that converts from the form the language uses to the data type. It takes one argument of type internal and returns the data type. |
comment |
string |
— | An optional comment about the transform. |
dependencies |
dependencies | — | Database objects this object is dependent upon. |
No other properties are accepted.
Source: schemata/transform.yml · Resolved JSON Schema: transform.json