Reputation: 4097
In Visual Studio 2013 i have a web api solution with 2 project:
1)StrokeInModel(that is entity framework database first)
2)MyProject (Web Api 2 with Individual Accounts project with reference to StrokeInModel project to access to the database)
Now i have changed the connection string in the Web.config to connect to my existing database:
<add name="StrokeInEntities" connectionString ......... />
And in the "StrokeInModel.Context.cs" i have the following code:
public partial class StrokeInEntities : DbContext
{
public StrokeInEntities()
: base("name=StrokeInEntities")
{
}
...
}
Now, for example, when i call this url:
http://localhost:port/api/Account/Register
passing this parameter as POST:
{
"UserName": "Alice",
"Password": "password123",
"ConfirmPassword": "password123"
}
seems that the registration is Ok. Anyway i can't see in the SQL Server Management the table where the user's username and password are stored in the existing database. If i recall the registration with the same parameters there's an error that the user is yet registered. Where is the user table in the existing database? (I don't have added any tables)
In the server explorer window i see the connection to my database with all my tables but don't see the user table!! So where is stored the user's signup information?
Upvotes: 1
Views: 4322
Reputation: 11591
Because the IdentityDbContext use the default connection string named "DefaultConnection", so you will have to change it as well.
More from here
Why is Asp.Net Identity IdentityDbContext a Black-Box?
Upvotes: 1