Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ChangeAbpTablePrefix is not working #5925

Closed
ibalmaci opened this issue Dec 8, 2020 · 7 comments
Closed

ChangeAbpTablePrefix is not working #5925

ibalmaci opened this issue Dec 8, 2020 · 7 comments

Comments

@ibalmaci
Copy link

ibalmaci commented Dec 8, 2020

When I use that line in DbContext:
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
base.OnModelCreating(modelBuilder);
modelBuilder.ChangeAbpTablePrefix<Tenant, Role, User>("");
}

Add-Migration command causes belowing error:
System.InvalidOperationException: Both 'TenantFeatureSetting' and 'EditionFeatureSetting' are mapped to the table 'AbpFeatures'. All the entity types in a hierarchy that don't have a discriminator must be mapped to different tables.

@maliming
Copy link
Member

maliming commented Dec 9, 2020

hi

  • Your Abp package version.
  • Your base framework: .Net Framework or .Net Core.

@ibalmaci
Copy link
Author

.Net Core MVC pack, 5.8.1 and higher versions...

@ismcagdas
Copy link
Member

@ibalmaci thanks, we will fix this.

@ibalmaci
Copy link
Author

@ismcagdas thanks. I tried and I saw that it is working...

@isbullaml
Copy link

Hi, @ibalmaci
Is this fixed? I would love to work on this if not.

@ibalmaci
Copy link
Author

ibalmaci commented Dec 12, 2020

Hi @isbullaml , yes, it's fixed with following commit.
#5932

But, if you use aspnetnoilerplate nuget packs, you need to wait the pack version 6.1.0

@ismcagdas
Copy link
Member

duplicate of #5877

@ismcagdas ismcagdas removed this from the v4.21 milestone Dec 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants