inspiring71 / mssql-sailsv1

Waterline Adapter to use between SailsV1 and a Sql Server DB

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

mssql-sailsv1

Fork from the Official Microsoft SQL Server adapter, by c*nect, for sails.js. Tested on SQL Server 2017, but should support any SQL Server 2005 and newer. This is an alpha version, there are several methods that needs to be implemented and i will keep implementing them over the time.

1. Install

$ npm install mssql-sailsv1 --save

2. Configure

config/datastore.js

{
  adapter: 'mssql-sailsv1',
  url: 'mssql://usr:pwd@host:port/DB?encrypt=false'
}
{
  adapter: 'mssql-sailsv1',
  user: 'usr',
  password: 'pwd',
  host: 'host',
  port: 'port', 
  database: 'DB',
  options: {
    encrypt: true   // use this for Azure databases
  }
}

For more options to connect please check mssql documentation.

3. Supported methods

.count() .create() .createEach() .destroy() .find() .populate() .update()

License

MIT

About

Waterline Adapter to use between SailsV1 and a Sql Server DB


Languages

Language:JavaScript 100.0%