How to Delete FILESTREAM Data in SQL Server

To delete inserted FILESTREAM data row in a FILESTREAM Table created using the collowing code:

CREATE TABLE [dbo].[FS_Table]
(
[Id] [int] IDENTITY(1,1) NOT NULL,
[UI] UNIQUEIDENTIFIER ROWGUIDCOL NOT NULL UNIQUE,
[FS_Data] [varbinary](max) FILESTREAM NULL
)

...use this T-SQL command (it will delete the row with Id = 1 in the dbo.FS_Table in the FS_Database):

Use FS_Database
GO
DELETE [dbo].[FS_Table]
WHERE Id = 1
GO

Delete_FILESTREAM_data

If the post helped you, please share it:
Pin It

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">