Bug #94687 EF Core 2.2 BIT(1) converting as short instead of bool
Submitted: 18 Mar 7:45
Reporter: Nitin Sharma Email Updates:
Status: Open Impact on me:
Category:MySQL Visual Studio Integration Severity:S2 (Serious)
Version:MySql.Data.EntityFrameworkCore (8.0.15) OS:Microsoft Windows
Assigned to: CPU Architecture:Any
Tags: Connector (8.0.13), dotnet core, MySql.Data.EntityFrameworkCore (8.0.15)

[18 Mar 7:45] Nitin Sharma
I am trying to generate db class from the existing database (DB first) through dotnet core CLI.

The db was perfectly working with EF5 with .net4.5 but after migrate to dotnet core the bit(1) field is not generating as bool instead it is generating as short.

Dotnet core - 2.2
MySql.Data.EntityFrameworkCore (8.0.15)
MySQl Connector Net 8.0.13

How to repeat:

Run following CLI command on VS console - 

dotnet ef dbcontext scaffold "server=localhost;port=3306;user=root;password=pass123;database=ws" MySql.Data.EntityFrameworkCore -c DataContext -o 'DataModel' -p Model -s Model --use-database-names -f

and after it is generating BIT(1) AS short filed 

"public short is_weight_wise { get; set; }"

I also tried with TinyInt(1) but no luck.