I am encountering this error when I try to scaffold an existing older version of .mdb (likely Access '97 version)
Could not load assembly 'Legacy.Test.RDBMSMigrations'. Ensure it is referenced by the startup project 'Legacy.Test.RDBMSMigrations'.
In Visual Studio my project is the default startup project and default project on PMC
command I ran via PMC
Scaffold-DbContext -Connection "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\RDBMS\cdb2.mdb;Jet OLEDB:Database Password=mypassword;" -Provider EntityFrameworkCore.Jet -OutputDir CDB2\Models -ContextDir CDB2\Context -Project Legacy.Test.RDBMSMigrations -StartupProject Legacy.Test.RDBMSMigrations
or
Scaffold-DbContext -Connection "Driver={Microsoft Access Driver (*.mdb)}; Dbq=C:\RDBMS\cdb2.mdb; Pwd=mypassword;" -Provider EntityFrameworkCore.Jet -OutputDir CDB2\Models -ContextDir CDB2\Context -Project Legacy.Test.RDBMSMigrations -StartupProject Legacy.Test.RDBMSMigrations
Yet same error comes up, also same using the alternate dotnet ef dbcontext scaffold command via CLI
Any idea on what is wrong?
My project setup is as follows
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<PlatformTarget>x86</PlatformTarget>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="EntityFrameworkCore.Jet" Version="3.1.0-alpha.4" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="3.1.10">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Data.Odbc" Version="5.0.0" />
<PackageReference Include="System.Data.OleDb" Version="5.0.0" />
</ItemGroup>
</Project>
Originally posted by @olakusibe in #34 (comment)
I am encountering this error when I try to scaffold an existing older version of
.mdb(likely Access '97 version)Could not load assembly 'Legacy.Test.RDBMSMigrations'. Ensure it is referenced by the startup project 'Legacy.Test.RDBMSMigrations'.In Visual Studio my project is the default startup project and default project on PMC
command I ran via PMC
Scaffold-DbContext -Connection "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\RDBMS\cdb2.mdb;Jet OLEDB:Database Password=mypassword;" -Provider EntityFrameworkCore.Jet -OutputDir CDB2\Models -ContextDir CDB2\Context -Project Legacy.Test.RDBMSMigrations -StartupProject Legacy.Test.RDBMSMigrationsor
Scaffold-DbContext -Connection "Driver={Microsoft Access Driver (*.mdb)}; Dbq=C:\RDBMS\cdb2.mdb; Pwd=mypassword;" -Provider EntityFrameworkCore.Jet -OutputDir CDB2\Models -ContextDir CDB2\Context -Project Legacy.Test.RDBMSMigrations -StartupProject Legacy.Test.RDBMSMigrationsYet same error comes up, also same using the alternate
dotnet ef dbcontext scaffoldcommand via CLIAny idea on what is wrong?
My project setup is as follows
Originally posted by @olakusibe in #34 (comment)