Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating Licensing Info for NPM #31

Open
wants to merge 203 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
203 commits
Select commit Hold shift + click to select a range
0a57142
Added history file and added ability to do SELECT DISTINCT queries.
Jul 15, 2014
28eecca
Added history file.
Jul 16, 2014
6f3e8ef
Added ability to do DISTINCT statements.
Jul 16, 2014
e6f33de
Added the ability to handle aliases and we're now escaping identifier…
Jul 16, 2014
1023954
Added ability to do OR WHERE statements with or_where() method.
Jul 16, 2014
0a0dfbd
Added the ability to directly do LIKE statements with the methods: li…
Jul 16, 2014
6745b94
Added the ability to do myriad WHERE IN statements directly and resto…
Jul 16, 2014
fe03b5e
Added the ability to do FROM statements directly to do things like db…
Jul 16, 2014
786cff2
Enhanced security of join() statements.
Jul 17, 2014
62c175b
Fixed bug with where_in statements.
Jul 17, 2014
37d44c9
Added the ability to do call get_where().
Jul 17, 2014
6234cc5
Updated history file and fixed bug in how values were being escaped i…
Jul 17, 2014
d0a3e03
Added select_min, select_max, select_avg, and select_sum methods.
Jul 17, 2014
5345a0f
Fixed various bugs in protectIdentifiers, significanly increased secu…
Jul 21, 2014
cfc6f04
Added new features like or_having(), offset(), and set(). Modified up…
Jul 25, 2014
da25754
Removed the test folder from gitignore. Removed uneccessary test.js f…
Jul 25, 2014
1af92f4
More bug fixes and tests.
Jul 28, 2014
90a80f4
Fixed a major bug in how complex join conditions are escaped while al…
Jul 28, 2014
07d7009
Fixed bug causing the alias to not show up when supplying functions l…
Jul 28, 2014
da31ad2
Fixed bug causing the alias to not show up when supplying functions l…
Jul 28, 2014
2aaa0b3
Latest tests and testing out a test documentation with a test.md file…
Aug 4, 2014
d46d09f
Tests have been written for select, from, join, where, and orderby.
Aug 6, 2014
235c604
Latest tests... including a fix to order_by().
Aug 7, 2014
e4f5d95
Added a bunch of new tests and fixed a lot of code.
Aug 20, 2014
041355f
Making sure this is up to date on github.
Sep 17, 2014
e219a1b
Normalized the naming of methods and functions in the query builder a…
Sep 24, 2014
a110f1b
MAJOR departure from node-mysql-activerecord. This update is actually…
Oct 3, 2014
1c44b9f
A lot of documentation written.
Oct 6, 2014
385d638
More documentation changes/additions.
Oct 6, 2014
e8462f3
Fixed some bugs in testing and writing documentation as well as added…
Oct 7, 2014
e69c9f2
Additional documentation. Just trying to keep it up to date.
Oct 7, 2014
54ac2c0
Added a table of contents.
Oct 7, 2014
b274883
A lot more documentation and some random/minor bug fixes.
Oct 7, 2014
0739d69
Removed index_old.js file.
Oct 7, 2014
b27b4bb
Trying checkmarks instead of X's in tables.
Oct 8, 2014
2223cac
Fixed some formatting issues in the readme.md
Oct 8, 2014
207c178
Fixed some more formatting issues in the readme.md
Oct 8, 2014
68ae43e
Rearranged the documentation a little bit as well as added some new '…
Oct 8, 2014
66aa42f
Added the scaffolding for the rest of the API documentation.
Oct 8, 2014
d8272ad
Added documentation for the update method.
Oct 9, 2014
5afc3ad
Clarified some of the documentation. Added tests for get(). Fixed the…
Nov 14, 2014
41b3ecf
Added travis-ci functionality.
Nov 14, 2014
84b3bcc
Updated history to reflect addition of travis-ci.
Nov 14, 2014
185ef7b
Fixed travis yaml file.
Nov 14, 2014
a65c51f
Removed compatibility for Node < 0.10 in travis YML.
Nov 14, 2014
57bcd15
Added travis build tag to README.
Nov 14, 2014
684720a
Clarified some documentation and added get_where() to to the unit tests.
Nov 17, 2014
7abf493
Fixed a typo in the test-get unit tests.
Nov 17, 2014
f2f1cef
Updated/fixed documentation, fixed count() methods in builder and exe…
Nov 17, 2014
b1dc2e0
Made some changes to how pool connections can be passed through itera…
Nov 18, 2014
64fb900
Minor clarification in execution method docs.
Nov 18, 2014
f59339e
Added some more documentation for how to re-use connections from pools.
Nov 18, 2014
aa16a42
Major overhaul to fix QueryBuilder race condition issues when working…
Nov 21, 2014
8408a21
Removed invalid tests that I'm working on so CI will work.
Nov 21, 2014
d838818
Fixed broken tests.
Nov 24, 2014
f4a1728
Changed test reporter to look better on Travis CI.
Nov 24, 2014
133a841
Documentation for the 'Other Library-Specifc Methods' section. Update…
Jan 30, 2015
e8e8b10
Added line item to the HISTORY file.
Jan 30, 2015
dd37e16
Fixed bug where set value was being converted to null when falsy valu…
Jan 30, 2015
6939112
A bunch of new documentation and a working update_batch method.
Feb 4, 2015
e0cc0c0
Added documentation for the set() method.
Feb 4, 2015
718eb3c
Minor tweak to update_batch documentation.
Feb 4, 2015
5288f35
Updated documentation for the query compile methods and fixed a bug w…
Feb 5, 2015
c233c53
Added aliases to query compilation methods.
Feb 5, 2015
a3eb44a
Added truncate() and empty_table() methods, fixed a potential issue w…
Feb 5, 2015
d7a95ba
Added tests for insert_batch() and fixed a few bugs.
Feb 5, 2015
5574119
Added documentation for the and methods. Modified the documentation.
Feb 6, 2015
535257f
Wrote tests for the compilation methods.
Feb 6, 2015
6bd2043
Added database creation to travis_ci YML.
Feb 6, 2015
7864459
Fixed indentation in travis ci config.
Feb 6, 2015
c5477e8
Added testing for the MySQL connection adapter.
Feb 9, 2015
720fffb
Updated some connection settings documentation.
Feb 9, 2015
bf21429
Added some mock data for travis. Hopefull it works.
Feb 10, 2015
43cdf79
Updated paths in before_scripts scripts for travis.
Feb 10, 2015
f101e98
Added additional tests for the QueryBuilder adapter.
Feb 10, 2015
7808b64
Updated some formatting of the documentation.
Feb 11, 2015
e7490a5
Fixed some checks in the querybuilder library.
Feb 11, 2015
463cfb1
Fixed some checks for valid where and set clauses.
Feb 17, 2015
8d21086
Fixed a bug causing inserts to fail due to paranthesis. Fixed undefin…
Feb 17, 2015
34ca478
Fixed bug in insert_batch.
Jul 27, 2015
d4e983d
Fixed some small bugs. Tests should all be passing now.
Sep 4, 2015
6a02e87
Fixed a few minor bugs
Sep 4, 2015
b1e9c52
Switched from tabs to spaces in some main files.
Sep 4, 2015
31f97b4
Removed paranthesis for the FROM clause string builder method and upd…
Oct 13, 2015
ff34d48
Upped minor version because of bug fix related to building the FROM c…
Oct 13, 2015
d81227d
Update README.md
kylefarris Dec 14, 2015
3789a45
Updated README.md
kylefarris Dec 14, 2015
9436e11
Update README.md
kylefarris Dec 14, 2015
33e1bf4
Update README.md
kylefarris Dec 14, 2015
6015143
Fixed bugs in insert_ignore and get_where methods.
Dec 14, 2015
0ae2e4f
Upgrade to v0.11.0 because of fixed bugs in insert_ignore and get_whe…
Dec 14, 2015
4e5f8d3
Fixed a bug where the db connection settings passed into the construc…
Apr 5, 2016
0ad4512
Patching due to db connection settings reference being modified by li…
Apr 5, 2016
4b2f272
Removed some uneccessary bloat and updated the MySQL version.
Apr 5, 2016
73d3248
Upping minor due to removal of bloat and upping version of MySQL depe…
Apr 5, 2016
0fbb727
fix reference to var sqls
Sep 5, 2016
b609901
Cleaned up README file and added new valid value to set method. Fixes #3
Apr 26, 2017
05c1e61
Fixed build issues on Travis CI.
Apr 26, 2017
a38230c
Removed another reference to underscore.
Apr 26, 2017
0cb3971
Updated node version for Travis.
Apr 26, 2017
931a9ed
0.13.0
Apr 26, 2017
ad66e29
Merge pull request #4 from malles/patch-1
kylefarris Apr 26, 2017
7cfc28a
Minor tweak.
Apr 26, 2017
380bf06
0.14.0
Apr 26, 2017
ca4bf6d
Fixed and documented the join method's escape parameter.
Apr 27, 2017
c766b29
0.15.0
Apr 27, 2017
7d46469
Changed .match to .test for better preformance (and because in those …
0styx0 Jun 15, 2017
355815d
Changed many instances of stuff like parameterVar = parameterVar || n…
0styx0 Jun 15, 2017
874b3c1
Traded var for let or const to make scoping clearer
0styx0 Jun 15, 2017
e8bb209
Traded var for const when variable equals function or require
0styx0 Jun 15, 2017
e1646cf
Changed all variable declarations to const or let instead of var
0styx0 Jun 15, 2017
db26335
Changed .match to .test since only looking for boolean
0styx0 Jun 15, 2017
c6a8451
Use built in method to check if variable is an array
0styx0 Jul 11, 2017
03d4c7b
Added arrow functions
0styx0 Jul 11, 2017
2790b24
Replaced all functions that did not complain when I did it, with arrows
0styx0 Jul 11, 2017
f4fd135
Traded some of that for this (literally:))
0styx0 Jul 11, 2017
58e23b5
Switched tons of functions to arrows
0styx0 Jul 11, 2017
1727c04
Made checking if var is array easier
0styx0 Jul 11, 2017
62940d7
Got the last of the functions that didn't throw errors (depending on …
0styx0 Jul 11, 2017
1a50739
Removed self
0styx0 Jul 11, 2017
501db0d
Removed return from arrow functions with 1 statement
0styx0 Jul 11, 2017
d87aa3b
Merge pull request #12 from DovidM/master
kylefarris Jul 12, 2017
4f424f1
1.0.0
Jul 26, 2017
ee64fe0
Fixed a bug where non-strings or non-array-of-strings could be passed…
Aug 10, 2017
57b7d80
1.0.1
Aug 10, 2017
8162e0b
Fixed a bug dealing with the default 'driver' param value in the Quer…
Aug 22, 2017
3bec22f
1.0.2
Aug 22, 2017
f9d7e94
Fixed a bug in how it's checking for valid connection types. Also upd…
Aug 22, 2017
5d194d2
1.0.3
Aug 22, 2017
8119ab7
Updated travis to always use dist: precise.
Aug 22, 2017
10e7af7
Fixes #20
kylefarris Feb 20, 2018
52e8171
Update mysql and test on more travis
genio May 17, 2018
fa7c957
Merge pull request #22 from kylefarris/update-dependencies
genio May 17, 2018
cf65b2e
update the history log
genio May 17, 2018
8913563
1.1.1
genio May 17, 2018
d8648aa
Fix a mysql escape string bug
genio May 18, 2018
e23d6ce
1.2.0
genio May 18, 2018
554acdc
bump minor version
genio May 18, 2018
ed66131
Updated documentation. Added a new test to check for functions in sel…
Jun 5, 2018
23be245
1.2.1
Jun 5, 2018
47a34bf
In reference to #21
kylefarris Jun 6, 2018
24ea9c3
Quick clarification
kylefarris Jun 6, 2018
8f17e3a
Marked "cluster" connection type as incomplete
kylefarris Jun 6, 2018
58f1f71
1.2.2
Jun 6, 2018
8410d95
Added MSSQL driver. Wrote adapter tests for MSSQL. Updated history an…
Jun 11, 2018
6e6d380
Switched to and instead of . All tests are adapter tests are passing.
Jun 12, 2018
5004a21
Got mock database stuff created and working using linux sql server.
Jun 13, 2018
6671b0d
Latest updates to the mssql adapter.
Jun 19, 2018
b009dd9
Converted all MySQL driver libraries to ES6 Class syntax. This fixes …
Jun 20, 2018
50efcdd
Updated MS SQL driver files to be all in the form of ES6 classes and …
Jun 21, 2018
611498e
Some random mode changes.
Jun 21, 2018
8cf9b6c
Re-named MySQL tests so they'd actually run in order.
Jun 21, 2018
6486bdb
Renamed MSSQL tests and added general test.
Jun 21, 2018
a153c0e
Fixed mock db creation script.
Jun 21, 2018
ac9d427
Added test for QB distinct.
Jun 21, 2018
74001ae
Trying to make the full mock database creation script functional for …
Jun 21, 2018
9015d8a
Modified some tests?
Jul 6, 2018
8f87566
These permissions changes are kinda making me crazy...
Jul 6, 2018
d393c5f
Seperated out the common methods and properties of the query builder …
Jul 10, 2018
0e28ac9
Hopefully getting the escaping to work properly. Slowly but surely.
Jul 11, 2018
9df3758
Trying to finish up the unit tests for the MSSQL driver.
Jul 17, 2018
b8a426a
Added the rest of the tests for the mssql driver. Added a new set of …
Jul 18, 2018
9290f4c
Updated README. Updated minimum Node version in package file to >= v8…
Jul 19, 2018
f48556e
All tests are passing now.
Jul 23, 2018
f908251
Added driver prefix to all tests. Normalized whitespace characters in…
Jul 25, 2018
a41f9d9
Fixed #18. Added a generic config file for test tests containing mock…
Jul 25, 2018
f14be2b
Wrote test to make sure multiple driver pools will work in conjunctio…
Jul 26, 2018
f867db1
Fixes #23
Jul 26, 2018
b6190cd
Added update batch test to mssql test suite.
Jul 26, 2018
a15ed96
Fixed #28
Jul 26, 2018
f6878b2
Fixed #30
Jul 26, 2018
c76300f
Fixed some code formatting things.
Jul 26, 2018
185be28
Fixes #34. Updated HISTORY file. Updated create_mock_dbs script to ha…
Jul 26, 2018
1ca8091
Accomplishes #32 - Implement insert_batch as described in docs
Jul 26, 2018
5a4cd3b
Updated package version to 2.0.0-beta
Jul 27, 2018
506be0d
Fixed driver definition for mssql.
Jul 27, 2018
a583322
bugfix: Return reserved identifier
Flamenco Aug 3, 2018
8be2c87
Remove trailing slash from driver path
Flamenco Aug 3, 2018
24bd2f0
Testing on Bionic and node 8-12 now
kylefarris Jul 26, 2019
b9a87d0
Fixed bug caused by array of data passed to the `insert` method
kylefarris Oct 28, 2019
3de3e61
Trying to get travis to test for mssql.
Oct 28, 2019
9b51478
Another attempt to get travis to test for mssql.
Oct 28, 2019
8b07a76
Removed mssql mock creation script to fix travis?
Oct 28, 2019
89a28c6
Bypassing mysql to see if mssql will work.
Oct 28, 2019
3cf715d
Attempting to get mysql built again...
Oct 28, 2019
a717863
MySQL tests are still failing and I don't know why...
Oct 28, 2019
77e5138
Stupid typo
Oct 28, 2019
6d27fb5
I feel like I'm actually getting closer...
Oct 28, 2019
7784d5a
Gotta make sure the mock data makes it into the MSSQL database.
Oct 28, 2019
dac21d6
Forcing mocha to quit when tests are done.
Oct 28, 2019
583f85c
2.0.0
Oct 28, 2019
6f1b396
Package file was not on the right version.
Oct 28, 2019
44ca4ea
2.0.2
Oct 28, 2019
08d0a13
First step to getting this module 'promisified'. Let's see what Travi…
Nov 8, 2019
5c78a0b
Fixed minor typo.
Nov 8, 2019
1877f54
Added promise functionality to connection and disconnect methods of M…
Nov 8, 2019
89194f2
Fixed issue with context in get_connection method on Pool adatpers.
Nov 8, 2019
e13ec91
Fixed issue with error handling on get_connection method on Pool adap…
Nov 8, 2019
7a17ec9
Testing promise API for querying with MySQL.
Nov 8, 2019
bcac545
Testing promise API for querying with MSSQL.
Nov 8, 2019
ce4bb55
Included the required dependencies for MSSQL adapter Promise support.
Nov 8, 2019
5e9fbee
2.1.0
Nov 8, 2019
59598c1
Major updates for the README and HISTORY files to reflect updates mad…
Nov 8, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.DS_Store
node_modules
npm-debug*
test
index2.js
build
22 changes: 22 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
before_script:
- sudo docker run --name=mssql-server-linux-latest -e 'ACCEPT_EULA=Y' -e 'MSSQL_SA_PASSWORD=Password123' -p 1433:1433 -d microsoft/mssql-server-linux:2017-latest
- sudo docker cp ./test/mssql/mock_data.sql mssql-server-linux-latest:mock_data.sql
- sudo docker cp ./test/mssql/mock_data2.sql mssql-server-linux-latest:mock_data2.sql
- ./test/mysql/create_mysql_mock.sh
- ./test/mssql/create_mssql_mock.sh
language: node_js
dist: bionic
node_js:
- "12"
- "11"
- "10"
- "9"
- "8"
services:
- mysql
- docker
test:
adapter: mysql2
database: mock_db
username: travis
encoding: utf8
108 changes: 108 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
# Changes

This file is a manually maintained list of changes for each release. Feel free
to add your changes here when sending pull requests. Also send corrections if
you spot any mistakes.

## v2.1.1 (2019-11-08)

* Updated documentation to reflect new Promise API support.

## v2.1.0 (2019-11-08)

* Added Promise support. Closes [#18](https://github.com/kylefarris/node-querybuilder/pull/52). Thanks for the contribution @AbhijetPokhrel!
* Added new tests to verify that Promise support is working.

## v2.0.2 (2019-10-28)

* Finally got testing working on Travis CI for MySQL and MSSQL.

## v2.0.0 (2018-06-15)

### Breaking Changes
* Changed the Query Builder instantiation syntax
* Passing an empty array to `where_in` and `where_not_in` no longer throws an error ([#34](https://github.com/kylefarris/node-querybuilder/issues/34))

# General Enhancements/Changes/Features
* Added mssql (t-sql) support using `tedious` as the underlying driver
* Updated class files to use new ES6 class syntax for easier-maintainability
* Added new options:
** `pool_min` (minimum number of pooled connections (`mssql` driver only))
** `acquireTimeout` (milliseconds before a timeout occurs during the connection acquisition)
* Added new query building method: `returning()` to allow for insert IDs to be returned. See docs for more info.
* Added new tests

### Bug Fixes
* Fixed [#18](https://github.com/kylefarris/node-querybuilder/issues/18)
* Fixed [#23](https://github.com/kylefarris/node-querybuilder/issues/23)
* Fixed [#26](https://github.com/kylefarris/node-querybuilder/issues/26)
* Fixed [#28](https://github.com/kylefarris/node-querybuilder/issues/28)
* Fixed [#30](https://github.com/kylefarris/node-querybuilder/issues/30)
* Fixed [#33](https://github.com/kylefarris/node-querybuilder/issues/33)


## v1.2.0 (2018-05-18)

* retroactive fix of this change log
* updated the mysql escape string to use the proper mysql method.

## v1.1.1 (2018-05-17)

* Updated package.json to always use the latest version of mysql 2.x

## v1.1.0 (2018-02-20)

* Fixed a bug where you could not insert with leading zeros. #20

## v1.0.3 (2017-08-22)

* Fixed a bug in how it's checking for valid connection types. Also updated tests to allow for an empty driver string in QueryBuilder constructor (defaults to 'mysql').

## v1.0.2 (2017-08-22)

* Fixed a bug dealing with the default 'driver' param value in the QueryBuilder contructor

## v1.0.1 (2017-08-10)

* Fixed a bug where non-strings or non-array-of-strings could be passed to the method and cause issues

## v1.0.0 (2017-07-26)

* Updated codebase to ES6

## v0.15.0 (2017-04-27)

* Fixed and documented the escape property of the `join` method.

## v0.9.0 (2015-02-05)

* Added this history file
* Added the ability to do `SELECT DISTINCT` queries
* We're doing better escaping of identifiers now
* Added the ability to use table/view prefixes directly (ex. `select * from users u`)
* Added the ability to do `OR WHERE` statements with `or_where()` method.
* Added the ability to do `LIKE` statements directly (new methods: `like()`, `not_like()`, `or_like()`, `or_not_like()`)
* Restored ability to do `WHERE IN(...)` statements by passing an array as the second param to `where()`
* Added the ability to do `[OR] WHERE [NOT] IN(...)` statements directly (new methods: `where_in()`, `or_where_in()`, `where_not_in()`, `or_where_not_in()`)
* Added the ability to do `FROM` statements directly for `SELECT` and `DELETE` queries (new method: `from()`) (ex. db.from('foo').get(() => ...))
* Identifiers will now be properly escaped in `JOIN` statements.
* Added the ability to call `get_where()` as a shorthand to `get()` and `where()` (ex. `db.get_where('table',{foo: 'bar'},() => ...);`)
* Added the ability to call `select_min()`, `select_max()`, `select_avg()`, and `select_sum()`.
* Significanly improved security, helping to prevent SQL injection attacks.
* Added ability to do `OR HAVING` statements with `or_having()` method
* Added ability to add an offset directly without using the `limit()` method by using the `offset()` method.
* Added ability to set `SET` values for updates and inserts using the `set()` method.
* `UPDATE` statements now support `ORDER BY` clauses which can be added to the query using the `order_by()` method.
* The `update()` method's 3rd parameter can now either be the callback (as always) or a `WHERE` clause (ex. 'foo = "bar"' or {foo:'bar', id: 3}). If a where clause is provided, the callback is now the 4th parameter. This change is fully backwards-compatible with the previous version of this module.
* New package dependencies (for testing): chai and mocha.
* Tests have been written for better-ensuring future enhancements and fixes to not break functionality
* Library has been broken into 3 objects to allow for prpoer testing. This won't affect the API and is fully-backwards compatible with the previous version.
* Officially announcing that how third parameter of the `where()` method works is deprecated... starting with v1.0.0, third param will be `(bool) escape` and not `(bool) isRaw`. So, all calls to this method using the 3rd parameter will, in future, have to be changed by converting `true` to `false` and vice versa. This is so that we have a consistent API throughout the library.
* Name officially changed to node-mysql-querybuilder.
* Author officially changed to Kyle Farris due to the substantial changes to this fork and Martin Tajur demoted to primary contributor (thanks for the great starting place Martin!!)
* Name of internal methods and properties have been normalized to use the "lower_case" syntax.
* Dependency for node-mysql upgraded to 2.5.
* travis-ci functionality added to repository
* Added public `escape()` method
* Added funtional `update_batch()` method.
* Added `truncate()` and `empty_table()` methods.
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
TESTS = test/mysql/*.js test/mssql/*.js test/*.js
#TESTS = test/mssql/01-tests-where_in.js
#TESTS = test/05-multiple-drivers.js
test:
mocha --exit --timeout 5000 --reporter spec $(TESTS)

.PHONY: test
Loading