I know that by default EF code first sets StoreGeneratedPattern = Identit it's OK. But I want to include some part of the data via the SQL script. I know that at the time only one table can be on the But when I try to run I get an error and I want to set a specific ID to set up a special argument set. How can I solve my problem? SET IDENTITY_INSERT rules;
USE [GameDatabase] GO GO ON ATNSINNLS SET QUOTED_IDENTIIFIER SET - Rules on Game SET IDENTITY_INSERT RulesOfGames; RulesOfGames (RulesOfGameId, MaxScore, IsPossibleEqualsScore) INSERT (1, 20, 1) in values; SET IDENTITY_INSERT RulesOfGames OFF; - Kindsport SET IDENTITY_INSERT RulesOfGames on; Include in prices (KindSportId, Name, RulesOfGame_RulesOfGameId) Value (1, 'ÑÑ ?? Ñ ?? Ð ± оР»', 1); SET IDENTITY_INSERT Consort of Off;
Message 8107, Level 16, State 1, Line 3 IDENTITY_INSERT Table 'GameDatabase.dbo.KindSports' is already running for table 'RulesOfGames' SET can not perform action for
No comments:
Post a Comment