I got this error "Format of the initialization string does not conform to specification starting at index 0."
while migrating.
my connection string given in
appsettings.json
"ConnectionStrings": {
"DefaultConnection": "Data Source=LAPTOP-P08F3TG1/ckary;Initial Catalog=Product;Integrated Security=True"
},
ApplicationDbcontext.cs
public class ApplicationDbContext:DbContext
{
public DbSet<Login> Logins { get; set; }
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
optionsBuilder.UseSqlServer("DefaultConnection");
}
please help to findout my mistake
correct answer or format to solve my error
2
Answers
Could you try this?
Try: