# SheetAttachments
## Documentation
The files and links attached to the sheets, their rows and their comments. A filter on sheet_id reads one sheet only.
- Catalog: `Smartsheet`
- Schema: `Sheets`
- Primary Keys: `attachment_id`
This is a read-only table. The Smartsheet API may not support changing the data or the Invantive UniversalSQL driver for Smartsheet does not cover it. In the latter case, please use the table NativePlatformScalarRequests to upload data to the Smartsheet API.
## Table Columns
The columns of the table `SheetAttachments` are shown below. Each column has an SQL data type.
| Name | Data Type | Label | Required | Documentation |
|---|:---:|---|:---:|---|
| `attachment_id` | `int64` | | ☑ | The id of the attachment. |
| `attachment_sub_type` | `varchar2` | | ☐ | For a Google Drive file: DOCUMENT, SPREADSHEET, PRESENTATION, PDF or DRAWING; for Egnyte: FOLDER. |
| `attachment_type` | `varchar2` | | ☐ | Where the file lives: FILE for an upload, or BOX_COM, DROPBOX, EGNYTE, EVERNOTE, GOOGLE_DRIVE, LINK or ONEDRIVE. |
| `created_at` | `datetime` | | ☐ | When the attachment was added, UTC. |
| `created_by_email` | `varchar2` | | ☐ | The e-mail address of who added the attachment. |
| `mime_type` | `varchar2` | | ☐ | The MIME type of an uploaded file. |
| `name` | `varchar2` | | ☐ | The name of the file or link. |
| `parent_id` | `int64` | | ☐ | The sheet, row or comment the attachment is on. |
| `parent_type` | `varchar2` | | ☐ | What the attachment is on: SHEET, ROW or COMMENT. |
| `sheet_id` | `int64` | | ☑ | The sheet of the attachment. |
| `size_in_kb` | `int64` | | ☐ | The size of an uploaded file in kilobytes. |
## Foreign Keys
The values of these columns refer to a row of another table.
| Columns | Referenced Table | Referenced Columns | Guarantee |
|---|---|---|---|
| `sheet_id` | [[Sheets-Sheets\|Sheets.Sheets]] | `sheet_id` | Declared by the connector, not enforced by the platform |
| `sheet_id`, `parent_id` | [[Sheets-SheetRows\|Sheets.SheetRows]] | `sheet_id`, `row_id` | In words only: A row only when parent_type is ROW; otherwise the sheet or a comment. |