Skip to content

Error connecting to MSSQL database with clustering enabled #1200

@nick-w-nick

Description

@nick-w-nick

After connecting to a MSSQL database that has clustering/availability zones enabled, I am getting this error message after making a query:

UnexpectedTokenError: Unexpected token `ENVCHANGE` in `RequestTokenHandler`
    at RequestTokenHandler.onDatabaseMirroringPartner (/Users/user/Documents/GitHub/service-name/node_modules/tedious/src/token/handler.ts:140:11)

This error is not present in our other identical MSSQL databases where clustering is disabled.

I realize this seems to be an error stemming from tedious, but I thought this repo would be more suitable to ask for help, as we are also using tedious with Sequelize and have no issues connecting to the exact same database.

We have also verified that we don't seem to have database mirroring enabled, but are somehow still getting sent a DatabaseMirroringPartner event, which is causing the unhandled exception to be thrown.

Any help or insight would be much appreciated.

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    built-in dialectRelated to a built-in dialectmssqlRelated to MS SQL Server (MSSQL)questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions