Category SQL

ASP.NET Core 1.0 with MySQL and Entity Framework Core

This article shows how to use MySQL with ASP.NET Core 1.0 using Entity Framework Core. Code: https://github.com/damienbod/AspNet5MultipleProject 2016.12.01: Updated to ASP.NET Core 1.1 Thanks to Noah Potash for creating this example and adding his code to this code base. The Entity Framework MySQL package can be downloaded using the NuGet package SapientGuardian.EntityFrameworkCore.MySql. At present no […]

Creating and requesting SQL localized data in ASP.NET Core

This article shows how localized data can be created and used in a running ASP.NET Core application without restarting. The Localization.SqlLocalizer package is used to to get and localize the data, and also to save the resources to a database. Any database which is supported by Entity Framework Core can be used. Code: https://github.com/damienbod/Angular2LocalizationAspNetCore 2017.01.07: […]

ASP.NET Core 1.0 using SQL Localization

This article shows how to use SQL localization in ASP.NET Core using an SQL database. The SQL localization in the demo uses Entity Framework Core to access a SQLite database. This can be configured to use any EF core provider. Code: https://github.com/damienbod/AspNet5Localization Library: https://github.com/damienbod/AspNet5Localization/tree/master/AspNet5Localization/src/Localization.SqlLocalizer NuGet package: https://www.nuget.org/packages/Localization.SqlLocalizer/ 2016.11.22: Updated to .NET Core 1.1 2016.06.28: Updated […]

Experiments with Entity Framework Core and ASP.NET Core 1.0 MVC

The article shows some of the ways in which Entity Framework Core can be used together with ASP.NET Core 1.0 MVC. Both packages run on dotnet which makes it possible to run on Linux, Mac or Windows operating systems. The Entity Framework providers are implemented in separate data access projects using onion architecture. Code: https://github.com/damienbod/AspNet5MultipleProject […]

ASP.NET Core 1.1 MVC File Upload with MS SQL SERVER FileTable

This article shows how to upload and download files in ASP.NET Core 1.1 MVC and save the files to a MS SQL Server using FileTable. The data access for the application is implemented in a separate project and EF7 migrations is used to setup the select logic for the database. Code: https://github.com/damienbod/AspNet5FileUploadFileTable 2017.01.07: Updated to […]

MVC CRUD with Elasticsearch child, parent documents

This article demonstrates how to search for data in Elasticsearch using parent and child documents. The documents are all saved inside the same index and the child documents are saved on the same shard using the parent id as the routing. As in the previous ElasticsearchCRUD tutorials, an autocomplete in used to search for the […]

Transferring data to Elasticsearch from MS SQL Server using ElasticsearchCRUD and Entity Framework

This article shows how to transfer data from a MS SQL Server 2014 to Elasticsearch. The MS SQL Server is accessed using Entity Framework (Code first from a database). Elasticsearch documents are created using ElasticsearchCRUD and inserted in bulk requests. The Entity Framework entities can be used directly in ElasticsearchCRUD. Either the whole entity including […]