Skip to content

Commit ab324c7

Browse files
committed
database updated, readme modified
1 parent 9bf153b commit ab324c7

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

README.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,14 @@ Simple example of Entity Framework Core Code-First approach.
1313
- Microsoft.EntityFrameworkCore.SqlServer
1414
- Npgsql.EntityFrameworkCore.PostgreSQL
1515

16+
## Entity Framework CLI commands
17+
18+
- dotnet-ef migrations add SqlServerInitialMigration --project CodeFirst.DataAccess --context SqlServerContext
19+
- dotnet-ef migrations add PostgreSqlInitialMigration --project CodeFirst.DataAccess --context PostgreSqlContext
20+
- dotnet-ef database update --project CodeFirst.DataAccess --context SqlServerContext
21+
- dotnet-ef database update --project CodeFirst.DataAccess --context PostgreSqlContext
22+
- dotnet ef migrations remove
23+
1624
## Roadmap
1725

1826
- Create a separate project Models, where data models are stored
@@ -30,4 +38,6 @@ Simple example of Entity Framework Core Code-First approach.
3038
- Update SqlServerContext with BDSet<T> and override methods OnConfiguring and OnModelCreating.
3139
- Update PostgreSqlContext with BDSet<T> and override methods OnConfiguring and OnModelCreating.
3240
- Create migration for SqlServerContext, use CLI command: dotnet-ef migrations add SqlServerInitialMigration --project CodeFirst.DataAccess --context SqlServerContext
33-
- Create migration for PostgreSqlContext, use CLI command: dotnet-ef migrations add PostgreSqlInitialMigration --project CodeFirst.DataAccess --context PostgreSqlContext
41+
- Create migration for PostgreSqlContext, use CLI command: dotnet-ef migrations add PostgreSqlInitialMigration --project CodeFirst.DataAccess --context PostgreSqlContext
42+
- Update SQL Server database: use: dotnet-ef database update --project CodeFirst.DataAccess --context SqlServerContext
43+
- Update Postgre SQL database, use: dotnet-ef database update --project CodeFirst.DataAccess --context PostgreSqlContext

0 commit comments

Comments
 (0)