Add Table Column
add_table_columnAdds a column to a ServiceNow table with field label and form layout captured and verified, ensuring the schema change is recorded in the current working update set.
Instructions
Add a column to a table, as the Columns related list does, with its Field Label and form layout captured and verified. The update set must be the working set (set_current_update_set): the platform captures schema changes only into the current set. The platform's prefix (u_ in Global, _ on another application's table) is added when missing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | No | A sys_glide_object name: string (default), integer, boolean, glide_date_time, reference, glide_list, ... | |
| label | Yes | The column label. | |
| scope | No | The record's application: its scope name (e.g. "x_acme_app"), or "global". Give this or scope_id. | |
| table | Yes | The table. | |
| column | Yes | The column name, lower case. | |
| instance | No | The ServiceNow instance auth alias to connect to. This is the alias configured via `snc configure` (e.g., "myinstance", "prod", "test"). The user will typically refer to this by name when saying things like "on my myinstance instance". If not provided, falls back to the SN_AUTH_ALIAS environment variable. | |
| scope_id | No | The record's application by sys_scope sys_id, instead of scope. | |
| reference | No | The referenced table: required for reference, optional for glide_list. | |
| max_length | No | Maximum length, for string types. | |
| update_set | Yes | sys_id of an In progress update set of that application (create_update_set). The capture is verified there; for adding a column and for layout saves it must also be the working set (set_current_update_set). | |
| acknowledge_upgrade_skip | No | Only for an installed Store application, and only after the user has reviewed the change: upgrades of that application then skip this file until the customization is reviewed. |