You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@ravensorb No, none. But, I designed db-migrate in the late versions to provide the most possible freedom to the community. Drivers are external, so everyone can just freely write their own driver. So if you're in a big need for it. It is not too hard to write a driver for old standard SQL databases like MSSQL is.
You can also look in the organisation at the other drivers for examples: https://github.com/db-migrate or even search in npm for community drivers. A driver always needs to start with the prefix db-migrate- so they're easy to find.
I will flag this as a feature request and with help wanted, since I wont invest work here. You could however also put a bounty on this issue via https://www.bountysource.com/, if the invested time gets payed I will also dedicate some time for this request or someone from the community, but I don't have enough time to spend them on all community request, also I would love to do so.
Feel free to reach out should you have any additional questions.
I started from a fork of https://github.com/db-migrate/pg . Took me about half a day to build it, and it's working. Without transactions for now. I'm sure there's room for improvement though. If you want to try, run: yarn add @devotis/db-migrate-mssql
I've not adapted the tests from pg to mssql yet, so no guarantees, but I'm able to migrate up and down. I tried only runSql thus far.
@wzrdtales Running into a problem here. Somebody already published db-migrate-mssql, but they did half the job since it's not working. I redid it from a fork of pg and it's working, but since the name db-migrate-mssql is already published at npm, I had to scope-publish mine at @devotis/db-migrate-mssql. But now when I use the driver mssql to migrate, db-migrate is telling me:
Error: No such driver found, please try to install it via npm install db-migrate-mssql or npm install -g db-migrate-mssql
And that's correct, but the driver IS installed, just not under the conventionalized name. How about adding a repository configuration for that? Something like:
So, don't do yarn add @devotis/db-migrate-mssql for now, and if you already did, remove the line "@devotis/db-migrate-mssql": "1.0.1", from your pacakage.json
@christiaanwesterbeek Btw. always try to reach out the npm support and report them an inactive package. Of course try to contact the mssql package owner first and ask him to transfer it to you. Most people will gladly do that if their package is not being maintained anyways.
Hi, I work for a company named Level Up Development, and we published the db-migrate-mssql to allow db-migrate MSSQL support for several internal projects we are currently developing.
@christiaanwesterbeek - If you'd like to be added to our git repository as a collaborator - we'd be happy to add you, to help further the support for db-migrate's compatibility with MSSQL.
Reason we chose to extend support to MSSQL is because we believe DB-migrate is the first npm package to have written a database migration tool the right way.
Currently we've only added support for SQL script migrations - looking forward to adding more!
@ryd0rz Can you open this repo up to the public so we can contribute and report issues specific to this mssql driver? Others in the community would love to help contribute to this.
Also, it would be helpful to have you and @christiaanwesterbeek collaborate as it feels like he has built the full version of this driver (SQL and Object based). The main issue as you notice in this thread is that we have a terrible work around in order to connect the driver to the base db-migrate library.
@ryd0rz You mean your repo for db-migrate-mssql is not public? Why would you close source that one? You're missing out on contributions by the community.
Let's work together on a single mssql driver for db-migrate that all of us can contribute to.
Hey @ryd0rz, so I reviewed your github repo and there are just a lot of issues with your approach here. No tests, no readme, missing half of the functionality, committed node_modules to git, missing basic information in your package.json that connects npm to your repo, etc.
If you review everything that @christiaanwesterbeek published, you will see this supports all the key features that the rest of the drivers have. Honestly, it would be best for this community for you to transfer ownership of this npm package to @christiaanwesterbeek so everyone can utilize his version that aligns with what is supported.
PS. I mean this all in the most respectful way. Love everything you started and that you are in the community! It is great to see you putting yourself out there and contributing. Stay encouraged
Actually I don't need ownership of his repo. I just need to be able to publish to db-migrate-mssql on npm. I'm not sure if it works like this, but if @ryd0rz would unpublish his db-migrate-mssql on npm, then I can publish what's on https://github.com/devotis/db-migrate-mssql to db-migrate-mssql on npm.
I guess it's either this (option 1) or a feature (option 2) that I mentioned here #593 (comment) that would allow node-db-migrate to be configured with not just driver="mssql", but also repository="@devotis/db-migrate-mssql".
So I see two ways to handle this. Option 1 seems to me the path of least technical friction and best for new user adoption (that like to configure as little as possible to get it working)
@christiaanwesterbeek Yes option 1 is your best bet! If you follow that link it shows that they would actually transfer ownership of that npm package namespace so you can republish your version overtop of what is publish now. (Irrelevant of the repo). I tried to see if they could just unpublish but I think you can only unpublished a version, not the whole package.
@ryd0rz I see what you are saying but there will be no difference between these two scenarios.
Transfer ownership, the next published version would be 2.0.0 and your production apps (assuming your package.json is setup correctly) will remain on 1.0.0 until you choose to upgrade to 2.0.0 with full support
Go through an overhaul of your repo (or merge all of @christiaanwesterbeek's code in since it's all there), publish next version as 2.0.0 and your production apps will still remain on 1.0.0
You're advantage is that you remain in control of the opensource repo. In the meantime I guess I can create PR's to get your repo fixed up
Activity
wzrdtales commentedon Oct 30, 2018
@ravensorb No, none. But, I designed db-migrate in the late versions to provide the most possible freedom to the community. Drivers are external, so everyone can just freely write their own driver. So if you're in a big need for it. It is not too hard to write a driver for old standard SQL databases like MSSQL is.
I dedicated a section in the docs for this:
https://db-migrate.readthedocs.io/en/latest/Developers/contributing/#creating-your-own-driver
You can also look in the organisation at the other drivers for examples: https://github.com/db-migrate or even search in npm for community drivers. A driver always needs to start with the prefix
db-migrate-so they're easy to find.I will flag this as a feature request and with help wanted, since I wont invest work here. You could however also put a bounty on this issue via https://www.bountysource.com/, if the invested time gets payed I will also dedicate some time for this request or someone from the community, but I don't have enough time to spend them on all community request, also I would love to do so.
Feel free to reach out should you have any additional questions.
christiaanwesterbeek commentedon Apr 13, 2019
@ravensorb @wzrdtales I've built one today. Here it is: https://github.com/devotis/db-migrate-mssql
I started from a fork of https://github.com/db-migrate/pg . Took me about half a day to build it, and it's working. Without transactions for now. I'm sure there's room for improvement though. If you want to try, run:
yarn add @devotis/db-migrate-mssqlI've not adapted the tests from
pgtomssqlyet, so no guarantees, but I'm able to migrate up and down. I tried only runSql thus far.christiaanwesterbeek commentedon Apr 14, 2019
@wzrdtales Running into a problem here. Somebody already published
db-migrate-mssql, but they did half the job since it's not working. I redid it from a fork of pg and it's working, but since the namedb-migrate-mssqlis already published at npm, I had to scope-publish mine at@devotis/db-migrate-mssql. But now when I use the driver mssql to migrate, db-migrate is telling me:And that's correct, but the driver IS installed, just not under the conventionalized name. How about adding a
repositoryconfiguration for that? Something like:{ "prod": { "driver": "mssql", "repository": "@devotis/db-migrate-mssql", "user": {"ENV": "PRODUCTION_USERNAME"}, "password": {"ENV": "PRODUCTION_PASSWORD"} }, }christiaanwesterbeek commentedon Apr 14, 2019
For the time being, you guys can add this to your package.json and than yarn/npm install:
"db-migrate-mssql": "https://github.com/devotis/db-migrate-mssql",So, don't do
yarn add @devotis/db-migrate-mssqlfor now, and if you already did, remove the line"@devotis/db-migrate-mssql": "1.0.1",from yourpacakage.jsonwzrdtales commentedon Jun 1, 2019
Hey, sry for the delay. Today is again some Open Source Time free for me.
I will add support for name scoped packages. Have nothing to argue against that in general.
wzrdtales commentedon Jun 1, 2019
@christiaanwesterbeek Btw. always try to reach out the npm support and report them an inactive package. Of course try to contact the mssql package owner first and ask him to transfer it to you. Most people will gladly do that if their package is not being maintained anyways.
ryd0rz commentedon Sep 30, 2019
Hi, I work for a company named Level Up Development, and we published the db-migrate-mssql to allow db-migrate MSSQL support for several internal projects we are currently developing.
@christiaanwesterbeek - If you'd like to be added to our git repository as a collaborator - we'd be happy to add you, to help further the support for db-migrate's compatibility with MSSQL.
Reason we chose to extend support to MSSQL is because we believe DB-migrate is the first npm package to have written a database migration tool the right way.
Currently we've only added support for SQL script migrations - looking forward to adding more!
jpinkster commentedon Sep 30, 2019
@ryd0rz Can you open this repo up to the public so we can contribute and report issues specific to this mssql driver? Others in the community would love to help contribute to this.
Also, it would be helpful to have you and @christiaanwesterbeek collaborate as it feels like he has built the full version of this driver (SQL and Object based). The main issue as you notice in this thread is that we have a terrible work around in order to connect the driver to the base db-migrate library.
Thanks everyone!
christiaanwesterbeek commentedon Oct 1, 2019
@ryd0rz You mean your repo for db-migrate-mssql is not public? Why would you close source that one? You're missing out on contributions by the community.
Let's work together on a single mssql driver for db-migrate that all of us can contribute to.
wzrdtales commentedon Oct 1, 2019
Agreeing, there is no reason to close something that contributes to open source and giving back to the community.
ryd0rz commentedon Oct 1, 2019
Hey everyone, the repo is actually public...
Here's the repo:
https://github.com/ryd0rz/db-migrate-mssql
We can work on merging any PR and I can even add you @christiaanwesterbeek as a collaborator if you'd like.
jpinkster commentedon Oct 2, 2019
Hey @ryd0rz, so I reviewed your github repo and there are just a lot of issues with your approach here. No tests, no readme, missing half of the functionality, committed node_modules to git, missing basic information in your package.json that connects npm to your repo, etc.
If you review everything that @christiaanwesterbeek published, you will see this supports all the key features that the rest of the drivers have. Honestly, it would be best for this community for you to transfer ownership of this npm package to @christiaanwesterbeek so everyone can utilize his version that aligns with what is supported.
See link to understand how to transfer ownership: https://docs.npmjs.com/transferring-a-package-from-a-user-account-to-another-user-account
PS. I mean this all in the most respectful way. Love everything you started and that you are in the community! It is great to see you putting yourself out there and contributing. Stay encouraged
christiaanwesterbeek commentedon Oct 2, 2019
Actually I don't need ownership of his repo. I just need to be able to publish to
db-migrate-mssqlon npm. I'm not sure if it works like this, but if @ryd0rz would unpublish hisdb-migrate-mssqlon npm, then I can publish what's on https://github.com/devotis/db-migrate-mssql todb-migrate-mssqlon npm.I guess it's either this (option 1) or a feature (option 2) that I mentioned here #593 (comment) that would allow node-db-migrate to be configured with not just
driver="mssql", but alsorepository="@devotis/db-migrate-mssql".So I see two ways to handle this. Option 1 seems to me the path of least technical friction and best for new user adoption (that like to configure as little as possible to get it working)
jpinkster commentedon Oct 2, 2019
@christiaanwesterbeek Yes option 1 is your best bet! If you follow that link it shows that they would actually transfer ownership of that npm package namespace so you can republish your version overtop of what is publish now. (Irrelevant of the repo). I tried to see if they could just unpublish but I think you can only unpublished a version, not the whole package.
ryd0rz commentedon Oct 3, 2019
@jpinkster I will clean up my repo in attempt to make it worthy.
We're currently using this in production for several projects so it makes it a bit more complicated than transferring ownership.
jpinkster commentedon Oct 4, 2019
@ryd0rz I see what you are saying but there will be no difference between these two scenarios.
You're advantage is that you remain in control of the opensource repo. In the meantime I guess I can create PR's to get your repo fixed up
ryd0rz commentedon Oct 8, 2019
@jpinkster - your changes are merged and published. Apologies for the delay.
db-migrate-mssql@2.0.0
jessephelps commentedon Mar 2, 2022
Any updates on this?
ryd0rz commentedon Mar 2, 2022
Good Afternoon Jesse,
The changes were merged as of Oct 8, 2019 and published as db-migrate-mssql@2.0.0
Can I help you with something else?