1

i am trying to run the command Update-Database in package manager console. the following errors appears.

this is the connection string I tried using
"ConnectionStrings": { "sqlserver": "nvlohuqx:YXGg4spm1KAvIidbFufyLMt9HeCZMZDD@surus.db.elephantsql.com:5432/nvlohuqx" }

it showed this error

“Format Of The Initialization String Does Not Conform To Specification Starting At Index X”

and then after I changed the format for the connection string to the following:

"sqlserver": "Server=surus.db.elephantsql.com;Database=nvlohuqx;User Id=nvlohuqx;Password=YXGg4spm1KAvIidbFufyLMt9HeCZMZDD;"

I get this new error:

"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: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)"

Marco Maher
  • 351
  • 1
  • 9

1 Answers1

-3

I recommend use Ip instead of domain on Server = ""

  • Not a good idea. Just one reason among many: if you want an encrypted connection, you need a full server name to validate the certificate subject name. – Joel Coehoorn Jan 27 '23 at 01:21