Open xiaoweiliu945 opened 3 years ago
Indulge me in this because I truly don't know.
Why?
@imnotjames wonder typeorm support msnodesqlv8 Because typeorm use mssql and mssql uses tediousjs as default driver, while claiming msnodesqlv8 is an alternative driver here: https://github.com/tediousjs/node-mssql
But when I want to use typeorm with msnodesqlv8, I have the above issues.
I basically refer to this issue: https://github.com/typeorm/typeorm/issues/5830, force typeorm to use msnodesqlv8 driver by using this.mssql = PlatformTools.load("mssql/msnodesqlv8")
Then I got 7 failed test cases, here I only ran mssql tests.
We don't officially support msnodesqlv8
as of now.
As far as I can tell this is similar to writing a new driver because of some differences in where the parameter types need to come from, etc.
If you're requesting a new driver I can update this issue as such. I don't see how else we'd handle this.
Feel free to include information on how the tests are failing, though.
@imnotjames
oh I think this is more like a bug fix.
Because typeorm is using driver:mssql and mssql support both tedious and msnodesqlv8
, so technically msnodesqlv8
should work with typeorm, and I also saw you provided example code here using msnodesqlv8
: https://github.com/typeorm/typeorm/issues/5830#issuecomment-706973658.
I am thinking those failed 7 test scenarios are something need to be addressed or fixed. Not sure if I should call it a new feature, it might just be extra bug fix for driver:mssql
I did not provide any sample code there.
Still need more info on what the tests are doing that are failing.
I have a good feeling that they're not interoperable and there's issues that are not trivial to make work between the two underlying drivers even if the compatibility layer exists via the mssql package.
One reason to use the other driver - it supports Trusted_Connection
, where the default driver does not.
Is someone still working on that ? Are there many people interested ? I had to drop TypeORM on a specific project because I needed that driver, but making the right changes to implement it could be interesting 👀
Is someone still working on that ? Are there many people interested ? I had to drop TypeORM on a specific project because I needed that driver, but making the right changes to implement it could be interesting 👀
It's possible to make it work with a few minor changes in versions < 0.3.0
. I think the latest release of TypeORM
does include some of these changes and may support it out of the box. However, there are some issues with the driver itself. For example - https://github.com/tediousjs/node-mssql/issues/1385
Issue Description
Tests break when using msnodesqlv8 driver
Expected Behavior
Expect all test pass
Actual Behavior
Steps to Reproduce
this.mssql = PlatformTools.load("mssql")
withthis.mssql = PlatformTools.load("mssql/msnodesqlv8")
in order to use msnodesqlv8 driver. Seesrc/driver/sqlserver/SqlServerDriver.ts
wonder if there is a fix for this so I don't need this workaround.
My Environment
Additional Context
Relevant Database Driver(s)
aurora-data-api
aurora-data-api-pg
better-sqlite3
cockroachdb
cordova
expo
mongodb
mysql
nativescript
oracle
postgres
react-native
sap
sqlite
sqlite-abstract
sqljs
sqlserver
Are you willing to resolve this issue by submitting a Pull Request?