0

Пишу приложение под core 3.0, EF 6. Строка подключения: "DefaultConnection": "Server=(localdb)\\usersdb;Database=linkdb;Trusted_Connection=True;", в Startup эту же строку передаю, ошибки в строке нет. Инициализирую БД через контекст, через метод Database.EnsureCreated(). Вручную не пытался, хотел по принципу CodeFirst добиться.

Полный текст ошибки:

Microsoft.Data.SqlClient.SqlException: "A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 50 - Local Database Runtime error occurred. Указанный экземпляр LocalDB не существует.

0

1 ответ 1

0

Если кто столкнется, то решением было изменение строки подключения, а именно: usersdb на mssqllocaldb

Ваш ответ

By clicking “Отправить ответ”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Всё ещё ищете ответ? Посмотрите другие вопросы с метками или задайте свой вопрос.