Skip to content

ConnectionError: Failed to connect to {{host}}:1433 - Cannot call write after a stream was destroyed #931

Description

@bj9215

Error while connecting to Database (Sql Server 2008 R2)

I am using "mssql": "^5.1.0"

I am able to connect to localhost and SQL Server 2017

[Nest] 29632 - 07/29/2019, 9:34 PM [TypeOrmModule] Unable to connect to the database. Retrying (1)... +876ms
ConnectionError: Failed to connect to {{host}}:1433 - Cannot call write after a stream was destroyed
at Connection. (\nrwl\node_modules\mssql\lib\tedious.js:244:17)
at Object.onceWrapper (events.js:288:20)
at Connection.emit (events.js:200:13)
at Connection.socketError (\nrwl\node_modules\tedious\lib\connection.js:1098:12)
at Socket. (\nrwl\node_modules\tedious\lib\connection.js:971:14)
at Socket.emit (events.js:205:15)
at errorOrDestroy (internal/streams/destroy.js:107:12)
at onwriteError (_stream_writable.js:432:5)
at onwrite (_stream_writable.js:459:5)
at doWrite (_stream_writable.js:413:11)

Kindly suggest some solution :)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    IdleWaiting for more information for a while...

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions