How to use Entity Framework code-first to generate a clustered primary key? -
We have something in the SQL statement, some names have been omitted to save some space: < Pre> on [primary]) on ALLOW_ROW_LOCKS =, on the ALLOW_PROVOLOKKS =, What is the correct way to generate this complicated code? Handicap is the section outline of the code in the code first? I can not duplicate your problem Adjustment & gt; () .hasKey (a => a.Id) << / p> Generate looks like SQL:. CREATE TABLE [dbo] [Payment] ([PaymentId] [uniqueidentifier] No NULL, [Itemid] [int] zero, ... barrier [PK_Payment] with primary key cluster ([PaymentId] ASC) (PAD_INDEX = closed, STATISTICS_NORECOMPUTE = closed, IGNORE_DUP_KEY = I can probably not say just this [primary] TEXTIMAGE_ON [Primary]
HasKey (P = & gt; p.PaymentId)
Protected Override Zero OnModelCreating (DbModelBuilder modelBuilder) {modelBuilder.Entity & lt: When I use the following code / Ex>
CREATE TABLE [dbo] [adjust]] ([id] [uniqueidentifier] NULL, // Exclude removed from additional unrelated areas [PK_dbo Edmonton] Primary Key Cluster ([ID] ASC) ( [Primary] TEXTIMAGE_ON [Primary] on PAD_INDEX = closed, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON]
Comments
Post a Comment