ci-node-query
Advanced tools
Comparing version 1.2.0 to 1.2.1
@@ -14,6 +14,8 @@ "use strict"; | ||
* @param {Object} connObject - A connection object from the database library you are connecting with | ||
* @param {String} connLib - The name of the db connection library you are using, eg. mysql or mysql2 | ||
* @param {String} [connLib] - The name of the db connection library you are using, eg. mysql or mysql2. Optional if the same as drivername | ||
* @return {queryBuilder} | ||
*/ | ||
this.init = function (driverType, connObject, connLib) { | ||
connLib = connLib || driverType; | ||
var fs = require('fs'), | ||
@@ -20,0 +22,0 @@ qb = require('./query-builder'); |
@@ -233,3 +233,2 @@ 'use strict'; | ||
whereNull: function(field, stmt, conj) { | ||
conj = conj || 'AND'; | ||
field = driver.quoteIdentifiers(field); | ||
@@ -236,0 +235,0 @@ var item = field + ' ' + stmt; |
{ | ||
"name": "ci-node-query", | ||
"version": "1.2.0", | ||
"version": "1.2.1", | ||
"description": "A query builder for node based on the one in CodeIgniter", | ||
@@ -5,0 +5,0 @@ "author": "Timothy J Warren <tim@timshomepage.net>", |
@@ -26,5 +26,10 @@ #CI-Node-query | ||
// Three arguments: database type, database connection, database connection library | ||
// Three arguments: database type, database connection, database connection library | ||
var query = nodeQuery.init('mysql', connection, 'mysql2'); | ||
// The third argument is optional if the database connection library has the same name as the adapter, eg.. | ||
nodeQuery.init('mysql', connection, 'mysql'); | ||
// Can be instead | ||
nodeQuery.init('mysql', connection); | ||
// You can also retrieve the instance later | ||
@@ -31,0 +36,0 @@ query = nodeQuery.getQuery(); |
@@ -20,3 +20,3 @@ 'use strict'; | ||
var nodeQuery = require('../../lib/node-query'); | ||
var qb = nodeQuery.init('mysql', connection, adapterName); | ||
var qb = nodeQuery.init('mysql', connection); | ||
@@ -23,0 +23,0 @@ // Set up the test base |
@@ -25,3 +25,3 @@ 'use strict'; | ||
var nodeQuery = require('../../lib/node-query'); | ||
var qb = nodeQuery.init('pg', connection, adapterName); | ||
var qb = nodeQuery.init('pg', connection); | ||
@@ -28,0 +28,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3991716
55