Write C# code
EF Core handles the SQL for DB2 for i
With the NTi Data Provider Entity Framework Core extension, seamlessly map your .NET objects to DB2 for i tables and vice versa, without writing any SQL.
| Column | Type |
|---|---|
| PKID | INTEGER |
| NAME | VARCHAR(255) |
| VARCHAR(255) | |
| BIRTHDATE | DATE |
DB2 for i
on .NET standards
With EF Core, work with IBM i like any modern database.
Single codebase, multiple databases
With EF Core, application code is database-agnostic. SQL is generated automatically based on the database in use.
Standard .NET development
Same environment and tools as any standard .NET project. NTi provides access to IBM i data.
No impact on IBM i
EF Core coexists with existing IBM i applications. Current SQL queries can be retained.
Widely available skills
.NET developers already master EF Core. They can therefore work on IBM i without specific expertise.
Develop with modern .NET performance
Access DB2 for i natively from C#. EF Core abstracts the data access layer and generates optimized SQL automatically.
-
LINQ power
LINQ is the native C# language mechanism for querying data using strongly typed expressions, with IntelliSense support and compile-time validation. EF Core leverages LINQ to automatically generate SQL tailored for DB2 for i.
-
Automated CRUD operations
Create, read, update, and delete operations generated automatically. EF Core handles joins and complex relationships.
-
High-performance, secure SQL
SQL queries are generated automatically by EF Core, in a strongly typed, parameterized manner tailored for DB2 for i, ensuring performance, data consistency, and protection against SQL injection.
List<User> users = await context.Users
.Where(u => u.Name == "Smith")
.ToListAsync();
SELECT *
FROM USERS
WHERE NAME = 'Smith';
An extension
built specifically for IBM i
Precise DB2 type mapping
Native support for IBM i encodings (EBCDIC, Unicode) and exact mapping of DB2 for i types (CHAR, DECIMAL, DATE, etc.) to .NET types, including support for scalar functions.
Modern SQL
Leverage the DB2 for i SQL engine: integrity constraints, relationships, and indexes are handled by native DB2 for i mechanisms. EF Core relies directly on these capabilities without re-implementing them at the application layer.
Schema management
Precisely target the IBM i libraries used by the application. Schema configuration is managed on the .NET side, while preserving the existing database organization.
DB First or Code First
The choice is yours
DB First
Application modernizationFrom an existing database and with a single command, automatically generate the data access layer as well as the interface components of your .NET application
Key features
- Automatic scaffolding from an existing database
- Generate C# entities from the existing schema
- Coexistence with existing structures and business logic
- Compatibility with stored procedures and existing processing
Code First
New projectsStarting a new application? Develop without worrying about the database: tables, columns, and CRUD operations are generated automatically without writing a single line of SQL
The data model is defined by the application
- Data model defined in C#
- Schema creation and evolution through EF Core migrations
- Explicit mapping of tables, columns, and relationships
- Automatic generation of CRUD operations
Native integration within the.NET ecosystem
All modern .NET capabilities available directly on IBM i with the NTi EF Core extension
ASP.NET Identity
Manage users, roles, and permissions directly on DB2 for i.
Authentification
Native support for MFA and external login providers (Azure AD, Google, Okta).
DevOps & industrialization
Native integration with .NET tooling: NuGet, Docker, CI/CD, and standardized environments.
Business impact
With Entity Framework Core, NTi brings IBM i development into modern .NET practices.
Your teams work with IBM i through standard .NET practices.
With EF Core, .NET developers access DB2 for i natively, without requiring specialized IBM i expertise.
Start new application initiatives without rebuilding a dedicated IBM i data access layer.
With the technical foundation already established, teams move into feature development faster.
By relying on open, widely adopted standards, new applications avoid the accumulation of proprietary layers and custom-built components.
The result: fewer internal dependencies, clearer maintenance, and technical debt that remains controlled over time.
Using common patterns and tooling creates a consistent application foundation across the organization.
This simplifies code reviews, project transitions, DevOps automation, and overall IT governance.
Real-world examples
Build more, code less
Modern web applications delivered faster with .NET
Context
Enable customers to view their orders online.
Data is distributed across multiple IBM i tables (customers, orders, pricing).
Implementation with EF Core
- DB First approach: automatic generation of C# code from existing tables
- Developers work with C# objects instead of writing SQL
- EF Core automatically generates joins between tables
Outcomes
Delivery of a modern web portal where each customer securely accesses their own data, based on the business rules already defined in the IBM i ERP.
Context
Deploy a mobile application for on-site order pickers, with security aligned to corporate standards.
Objective: avoid any user management specific to IBM i.
Implementation with EF Core
- .NET backend implemented with EF Core and DB2 for i
- Use of ASP.NET Identity for identity management
- Authentication via Azure AD with MFA
- .NET MAUI or Blazor applications for mobile devices
Outcomes
Operators authenticate using their Microsoft account and access the application without IBM i identity management.
Field operations (scanning, validation, tracking) are
synchronized directly with DB2 for i through EF Core.
Context
An IBM i ERP that has become difficult to evolve. Need to isolate specific capabilities (e.g., shipping, logistics tracking) quickly without impacting the core application.
Implementation with EF Core
- Targeted extraction of a feature into a standalone .NET service
- Deployment of the service in a Docker container
- Access to IBM i data through EF Core, without duplication
- Independent API consumable by other applications
Outcomes
The isolated functionality evolves, is tested, and deployed independently.
The IBM i ERP remains stable while continuing to handle data persistence.
Any questions?
Yes.
With NTi, the Entity Framework Core extension can be used natively with DB2 for i, in the same way as with modern relational databases such as SQL Server, Oracle, or PostgreSQL.
NTi provides:
- An IBM i ADO.NET provider compliant with the contracts expected by .NET and EF Core.
- An Entity Framework Core extension purpose-built for DB2 for i.
C# entities are mapped directly to existing tables, without schema changes, without data duplication, and without direct exposure of the IBM i database.
Yes, as long as a provider can translate LINQ expressions into DB2 for i-specific SQL.
The EF Core extension delivered with NTi is built to meet this requirement.
NTi provides:
- Automatic generation of DB2 for i-specific SQL.
- Accurate mapping of DB2 data types to .NET types.
- Transaction management.
- IBM i library (schema) management.
The behavior remains aligned with standard Entity Framework Core mechanics: EF Core stays database-agnostic, with SQL translation handled by the NTi provider..
No, the approach is progressive and non-intrusive.
The NTi EF Core extension acts as an abstraction layer that generates SQL without requiring a paradigm shift.
EF Core can be introduced where it improves efficiency, while preserving:
- Existing SQL queries.
- Stored procedures.
- Existing IBM i programs and processing logic.
This hybrid approach enables the gradual adoption of EF Core without disrupting existing business logic or the IBM i application landscape.
EF Core is a data access layer that sits between .NET application code and the relational database. It is therefore naturally suited for applications that consume, expose, or transform business data.
With the NTi EF Core extension, Entity Framework Core is used on the .NET backend to develop:
- Web applications (ASP.NET Core).
- REST APIs.
- Business services.
- Microservices-based architectures.
These backend services can power:
- Web applications.
- Mobile applications.
- Other client applications.
DB2 for i remains the system of record, while applications are built using modern .NET development standards and tooling.
Yes.
The NTi EF Core extension relies on the .NET runtime and the provider itself, allowing it to run in standard .NET environments.
Applications using EF Core with NTi can run on:
- Windows.
- Linux.
- Docker containers.
- CI/CD pipelines for build and deployment.
.NET applications run in modern, standardized environments (server, container, or cloud) and connect to IBM i through NTi. IBM i remains the data backend, while the application itself stays fully portable and independent of the underlying infrastructure.