msallin / SQLiteCodeFirst

Creates a SQLite Database based on a EdmModel by using Entity Framework CodeFirst.
Apache License 2.0
610 stars 123 forks source link

"The login failed" while using CreateDatabaseIfNotExists #122

Closed nguillermin closed 6 years ago

nguillermin commented 6 years ago

I'm getting a SqlException: Cannot open database "default" requested by the login. The login failed. while using the Initializer Sample. Can't find any login or password set anywhere in App.config or anything. Connection string is

<add name="localDbLayer" connectionString="data source=app.db;" providerName="System.Data.SQLite.EF6" />

I'm assuming I'm missing a default setting somewhere? There is no database created at all.

nguillermin commented 6 years ago

You can close this, I was using the wrong base name/wrong name in App.config. I have a different error now, but that would be a different issue.