0

我有一张这样的桌子:

CREATE TABLE [dbo].[Files](
    [Id] [int] IDENTITY(1,1) NOT NULL,
    [FileId] [uniqueidentifier] ROWGUIDCOL  NOT NULL,
    [Name] [nvarchar](500) NOT NULL,
    [FileContent] [varbinary](max) FILESTREAM  NOT NULL,
    [Extinction] [nchar](5) NOT NULL,
 CONSTRAINT [PK__Files] PRIMARY KEY CLUSTERED 
(
    [Id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] FILESTREAM_ON [FileStream],
 CONSTRAINT [UQ___Files__3214EC063158B01B] UNIQUE NONCLUSTERED 
(
    [FileId] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] FILESTREAM_ON [FileStream]

并将其映射到我的模型中(由 EF 5 生成)。现在我可以使用 EF 从该表中插入或删除吗?谁能告诉我我该怎么做?

4

0 回答 0