Devart is glad to announce the release of dotConnect for PostgreSQL 7.7, Devart ADO.NET data provider for PostgreSQL with support for Entity Framework, LinqConnect (LINQ to PostgreSQL) and NHibernate. The new version offers you support for Database-First approach in Entity Framework Core via Package Manager Console, support for JSON functionality of PostgreSQL in Entity Framework, and other features.
Entity Framework Core Database-First Support
Entity Framework Core supports the Database-First approach via the Scaffold-DbContext command of Package Manager Console. This command scaffolds a DbContext and entity type classes for a specified database.
Now dotConnect for PostgreSQL also supports this command allowing you to quickly generate context and entity classes for an existing schema. In order for the database-first functionality to work, add the Devart.Data.Postgresql.Entity.EFCore.Design.dll assembly to the project references in addition to other necessary provider assemblies.
JSON Functionality Support in Entity Framework
dotConnect for PostgreSQL now supports the JSON functionality of the PostgreSQL database in Entity Framework v4 - v6.
With the new provider version you will be able to use JSON-specific functions in your LINQ to Entities queries. For the list of the supported functions and examples of how to use them, you can read our blog article: JSON Support in Entity Framework v4 - v6 in dotConnect for Oracle, MySQL, and PostgreSQL
Additionally, dotConnect for PostgreSQL can now be installed without adding its assemblies to the GAC automatically. We also have added Batch Updates support in Entity Framework Core, which will improve dotConnect for PostgreSQL performance.
Here is the complete list of dotConnect for PostgreSQL 7.7.794 features:
- The 'Do not install assemblies in the GAC' check box that allows disabling placing the provider assemblies to the GAC is added to the Install Wizard
- The bug with backing up PostGIS datatypes via the PgSqlDump class as varchar is fixed
- The bug with generating an error when using PgSqlMonitor on Linux is fixed
- The bug with not using parameters value in ParentRelation data in PgSqlDataTable.SelectCommand is fixed
- The bug with retrieving incorrect DateTimeOffset when UnpreparedExecute is set to true is fixed
- The bug with creating columns for a child table in a master-detail relation when a select command in the child table ends with a semicolon is fixed
- The exception message for invoking CreateDatabase() for the model which includes an association with missing end is improved
- The possibility to choose whether to add new entities to a diagram or not in Update From Database Wizard is implemented
- The behaviour is changed: now the DbContext template generates an additional partial class for the context class when "File Per Class" and "Generate Partial Class" are set to True (Entity Framework models)
- Entity Framework Core 1.1.0 is supported
- The Scaffold-DbContext NuGet command of Package Manager Console for generating a model basing on the existing database schema is supported in EF Core
- Batch Updates support in EF Core is added
- The PgSqlJsonFunctions and PgSqlJsonbFunctions classes are implemented in EF4/EF5/EF6 to use JSON/JSONB functions and operators in LINQ to Entities queries
- Signed versions of NetTopologySuite GIS library are supported in EF5/EF6
- NetTopologySuite 1.14 is supported in EF5/EF6
- GeoAPI 1.7.4 is supported in EF5/EF6
- The NetTopologySuiteSigned and NetTopologySuiteUnsigned members are added to the SpatialServiceType enum in EF5/EF6
- The config.DatabaseScript.Schema.DeleteDatabaseBehaviour option is supported in EF Core
- The behaviour is changed: the functionality of SpatialServiceType.NetTopologySuiteSigned is moved to Devart.Data.PostgreSql.Entity.EF5.dll / Devart.Data.PostgreSql.Entity.EF6.dll
- The behaviour is changed: the SQL statement CREATE/DROP SCHEMA is generated with the IF NOT EXISTS/IF EXISTS clause now
- The bug with shortening PK, FK, IX, UX names in the Code-First CreateDatabase/CreateDatabaseScript functionality when config.CodeFirstOptions.TruncateLongDefaultNames=True is fixed
- The bug with comparison in LINQ query when config.QueryOptions.UseCSharpNullComparisonBehavior=true is fixed
- The bugs with logical expressions in EF Core are fixed