Skip to content
This repository has been archived by the owner on Jan 16, 2024. It is now read-only.

HasDefaultSchema doesn't work with MySql #160

Closed
mciprijanovic opened this issue Mar 15, 2020 · 1 comment
Closed

HasDefaultSchema doesn't work with MySql #160

mciprijanovic opened this issue Mar 15, 2020 · 1 comment
Labels
bug Confirmed bug released Issue is resolved in a current release
Milestone

Comments

@mciprijanovic
Copy link

When generating DataContext from template, method HasDefaultSchema() is called within method OnModelCreating(). Designer does not allow to set db schema as empty field, but in MySql case I don't have schema and this field causes my code not to work. Workaround to set empty schema in partial method OnModelCreatedImpl() does not work since HasDefaultSchema() can not accept empty string. I found solution to edit template and delete line that renders this method.
I guess possible solution for this would be to set default schema field in designer as non mandatory and if the field is empty not to generate this line in DbContext generation.

@msawczyn msawczyn added the investigating Looking into this label Mar 15, 2020
@msawczyn msawczyn added bug Confirmed bug and removed investigating Looking into this labels Mar 18, 2020
@msawczyn msawczyn added this to the 2.0.0.0 milestone Mar 18, 2020
@msawczyn msawczyn added the pending release Issue is resolved in the current codebase, will be published with the next release label Mar 21, 2020
@msawczyn
Copy link
Owner

The designer's been changed to allow the Database Schema property to be empty. Thanks for the report.

msawczyn added a commit that referenced this issue Mar 22, 2020
Fix: HasDefaultSchema doesn't work with MySql (#160)
Fix: Issue with GeographyPoint: System.Data.Entities.Spatial not found for .Net Core 3.1 (#159)
@msawczyn msawczyn modified the milestones: 2.0.0.0, 2.0.0 Mar 27, 2020
@msawczyn msawczyn added released Issue is resolved in a current release and removed pending release Issue is resolved in the current codebase, will be published with the next release labels Apr 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Confirmed bug released Issue is resolved in a current release
Projects
None yet
Development

No branches or pull requests

2 participants