ADO.NET Provider for Smartsheet

Build 24.0.9175

Info_Attachments

Retrieve detailed information about Smartsheet attachments, which can be associated with comments, rows, or sheets, providing a comprehensive view of file dependencies.

Table Specific Information

Select

When getting data from this table the queries might be slow if you have a lot of sheets. To counter this, specifying SheetId is recommended. Also other parameters like DiscussionId, RowId, CommentId can be specified to get Attachments to the related object.

Retrieve all Attachments from all Sheets.

SELECT * FROM Info_Attachments

Retrieve all Attachments related to a Sheet.

SELECT * FROM Info_Attachments WHERE SheetId = '2940085806098308'

Retrieve all Attachments related to a discussion.

SELECT * FROM Info_Attachments WHERE SHEETId = '2940085806098308' AND DiscussionId = '8206230771525508'

Retrieve all Attachments related to a Row.

SELECT * FROM Info_Attachments WHERE SheetId = '2940085806098308' AND RowId = '6773684447799172'

Retrieve all Attachments related to a Comment.

SELECT * FROM Info_Attachments WHERE SheetId = '2940085806098308' AND CommentId = '1322606759569284'

Retrieve details of a specific Attachment.

SELECT * FROM Info_Attachments WHERE Id = '3053958945105796' AND SheetId = '2940085806098308'

Insert

You can attach a file to a specific row in a specific sheet. Fields required for Insert are SheetId, RowId, Name of the file and either FilePath or ContentEncoded.

INSERT INTO Info_Attachments (SheetId, RowId, Name, FilePath) VALUES ('8179839304787844', '4728727909230468', 'TestSheet.xlsx', 'G:\\\\TestSheet.xlsx')

INSERT INTO Info_Attachments (SheetId, RowId, Name, ContentEncoded) VALUES ('8179839304787844', '4728727909230468', 'TestSheet.xlsx', 'dGVzdGluZyBlbmNvZGVkIHRleHQ=')

Columns

Name Type ReadOnly References Description
Id [KEY] String False

A unique identifier assigned to each attachment for tracking and retrieval purposes.

Name String False

The user-assigned or system-generated name of the attachment, helping identify its content or purpose.

Url String False

A temporary URL that allows access to the attachment file for download or viewing.

UrlExpiresInMillis Long False

The lifespan, in milliseconds, of the temporary URL before it expires and becomes inaccessible.

AttachmentType String False

The category of the attachment, such as FILE or external integrations like GOOGLE_DRIVE, BOX_COM, or DROPBOX.

AttachmentSubType String False

Specifies the subtype for GOOGLE_DRIVE (for example, DOCUMENT, SPREADSHEET) or EGNYTE attachments (for example, FOLDER), providing further detail on the content format.

CreatedAt Timestamp False

The timestamp indicating when the attachment was first added to the system.

UserId String False

The unique identifier of the user who uploaded or created the attachment.

UserEmail String False

The email address of the user who added the attachment, used for contact or audit purposes.

UserName String False

The full name of the user who uploaded the attachment, displayed for reference. This is read-only.

MimeType String False

The file type of the attachment, expressed as a multipurpose internet mail extension (MIME) type (for example, image/png or application/pdf).

ParentType String False

Indicates the type of Smartsheet object the attachment is associated with, such as SHEET, ROW, or COMMENT.

ParentId String False

The unique identifier of the parent object (for example, sheet or row) that the attachment belongs to.

SizeInKb Long False

The size of the attachment file in kilobytes, applicable only for attachments of type FILE.

SheetId String False

The unique identifier of the sheet to which the attachment is linked.

RowId String False

The unique identifier of the row within a sheet where the attachment is associated.

DiscussionId String False

The unique identifier of the discussion thread to which the attachment is linked.

CommentId String False

The unique identifier of the comment in which the attachment is embedded.

FilePath String False

The file path on the local system used to insert the attachment into Smartsheet.

ContentEncoded String False

The BASE64-encoded representation of the file's content, used when uploading files.

Copyright (c) 2025 CData Software, Inc. - All rights reserved.
Build 24.0.9175