2014-10-23 10:53:16 -04:00
|
|
|
<!DOCTYPE html>
|
|
|
|
|
|
|
|
<html lang="en">
|
|
|
|
<head>
|
|
|
|
<meta charset="utf-8">
|
|
|
|
<title>DocStrap Module: node-query</title>
|
|
|
|
|
|
|
|
<!--[if lt IE 9]>
|
|
|
|
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
|
|
|
|
<![endif]-->
|
|
|
|
<link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">
|
|
|
|
|
|
|
|
<link type="text/css" rel="stylesheet" href="styles/site.cosmo.css">
|
|
|
|
|
|
|
|
</head>
|
|
|
|
|
|
|
|
<body>
|
|
|
|
<div class="container-fluid">
|
|
|
|
<div class="navbar navbar-fixed-top navbar-inverse">
|
|
|
|
<div class="navbar-inner">
|
|
|
|
<a class="brand" href="index.html">DocStrap</a>
|
|
|
|
<ul class="nav">
|
|
|
|
|
|
|
|
<li class="dropdown">
|
|
|
|
<a href="modules.list.html" class="dropdown-toggle" data-toggle="dropdown">Modules<b
|
|
|
|
class="caret"></b></a>
|
|
|
|
|
|
|
|
<ul class="dropdown-menu ">
|
|
|
|
|
|
|
|
<li>
|
|
|
|
<a href="module-adapter.html">adapter</a>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<li>
|
|
|
|
<a href="module-driver.html">driver</a>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<li>
|
|
|
|
<a href="module-helpers.html">helpers</a>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<li>
|
|
|
|
<a href="module-node-query.html">node-query</a>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<li>
|
|
|
|
<a href="module-query-builder.html">query-builder</a>
|
|
|
|
</li>
|
|
|
|
|
2014-10-27 10:35:44 -04:00
|
|
|
<li>
|
|
|
|
<a href="module-query-parser.html">query-parser</a>
|
|
|
|
</li>
|
|
|
|
|
2014-10-23 10:53:16 -04:00
|
|
|
|
|
|
|
</ul>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row-fluid">
|
|
|
|
|
|
|
|
|
|
|
|
<div class="span8">
|
|
|
|
|
|
|
|
<div id="main">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h1 class="page-title">Module: node-query</h1>
|
|
|
|
<section>
|
|
|
|
|
|
|
|
<header>
|
|
|
|
<h2>
|
|
|
|
node-query
|
|
|
|
</h2>
|
|
|
|
|
|
|
|
</header>
|
|
|
|
|
|
|
|
<article>
|
|
|
|
<div class="container-overview">
|
|
|
|
|
|
|
|
|
|
|
|
<dt>
|
|
|
|
<h4 class="name" id="module:node-query"><span class="type-signature"></span>require("node-query")<span class="signature">(drivername, connObject, connLib)</span><span class="type-signature"> → {queryBuilder}</span></h4>
|
|
|
|
|
|
|
|
|
|
|
|
</dt>
|
|
|
|
<dd>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="description">
|
|
|
|
<p>Create a query builder object</p>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h5>Parameters:</h5>
|
|
|
|
|
|
|
|
|
|
|
|
<table class="params table table-striped">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<th>Name</th>
|
|
|
|
|
|
|
|
|
|
|
|
<th>Type</th>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<th class="last">Description</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
|
|
|
|
<tbody>
|
|
|
|
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<td class="name"><code>drivername</code></td>
|
|
|
|
|
|
|
|
|
|
|
|
<td class="type">
|
|
|
|
|
|
|
|
|
|
|
|
<span class="param-type">String</span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<td class="description last"><p>The name of the database type, eg. mysql or pg</p></td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<td class="name"><code>connObject</code></td>
|
|
|
|
|
|
|
|
|
|
|
|
<td class="type">
|
|
|
|
|
|
|
|
|
|
|
|
<span class="param-type">Object</span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<td class="description last"><p>A connection object from the database library you are connecting with</p></td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<td class="name"><code>connLib</code></td>
|
|
|
|
|
|
|
|
|
|
|
|
<td class="type">
|
|
|
|
|
|
|
|
|
|
|
|
<span class="param-type">String</span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<td class="description last"><p>The name of the db connection library you are using, eg. mysql or mysql2</p></td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dl class="details">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dt class="tag-source">Source:</dt>
|
|
|
|
<dd class="tag-source">
|
|
|
|
<ul class="dummy">
|
|
|
|
<li>
|
|
|
|
<a href="node-query.js.html">node-query.js</a>,
|
|
|
|
<a href="node-query.js.html#sunlight-1-line-15">line 15</a>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</dd>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h5>Returns:</h5>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dl>
|
|
|
|
<dt>
|
|
|
|
Type
|
|
|
|
</dt>
|
|
|
|
<dd>
|
|
|
|
|
|
|
|
<span class="param-type">queryBuilder</span>
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dl class="details">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dt class="tag-source">Source:</dt>
|
|
|
|
<dd class="tag-source">
|
|
|
|
<ul class="dummy">
|
|
|
|
<li>
|
|
|
|
<a href="node-query.js.html">node-query.js</a>,
|
|
|
|
<a href="node-query.js.html#sunlight-1-line-3">line 3</a>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</dd>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
|
|
|
|
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="clearfix"></div>
|
|
|
|
<footer>
|
|
|
|
|
|
|
|
|
|
|
|
<span class="copyright">
|
|
|
|
DocStrap Copyright © 2012-2014 The contributors to the JSDoc3 and DocStrap projects.
|
|
|
|
</span>
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<span class="jsdoc-message">
|
|
|
|
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.3.0-alpha9</a>
|
2014-10-31 11:58:12 -04:00
|
|
|
on Fri Oct 31st 2014 using the <a
|
2014-10-23 10:53:16 -04:00
|
|
|
href="https://github.com/terryweiss/docstrap">DocStrap template</a>.
|
|
|
|
</span>
|
|
|
|
</footer>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="span3">
|
|
|
|
<div id="toc"></div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<br clear="both">
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<!--<script src="scripts/sunlight.js"></script>-->
|
|
|
|
<script src="scripts/docstrap.lib.js"></script>
|
|
|
|
<script src="scripts/bootstrap-dropdown.js"></script>
|
|
|
|
<script src="scripts/toc.js"></script>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
$( function () {
|
|
|
|
$( "[id*='$']" ).each( function () {
|
|
|
|
var $this = $( this );
|
|
|
|
|
|
|
|
$this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
|
|
|
|
} );
|
|
|
|
|
|
|
|
$( "#toc" ).toc( {
|
|
|
|
anchorName : function ( i, heading, prefix ) {
|
|
|
|
return $( heading ).attr( "id" ) || ( prefix + i );
|
|
|
|
},
|
|
|
|
selectors : "h1,h2,h3,h4",
|
|
|
|
showAndHide : false,
|
|
|
|
scrollTo : "100px"
|
|
|
|
} );
|
|
|
|
|
|
|
|
$( "#toc>ul" ).addClass( "nav nav-pills nav-stacked" );
|
|
|
|
$( "#main span[id^='toc']" ).addClass( "toc-shim" );
|
|
|
|
$( '.dropdown-toggle' ).dropdown();
|
|
|
|
// $( ".tutorial-section pre, .readme-section pre" ).addClass( "sunlight-highlight-javascript" ).addClass( "linenums" );
|
|
|
|
|
|
|
|
$( ".tutorial-section pre, .readme-section pre" ).each( function () {
|
|
|
|
var $this = $( this );
|
|
|
|
|
|
|
|
var example = $this.find( "code" );
|
|
|
|
exampleText = example.html();
|
|
|
|
var lang = /{@lang (.*?)}/.exec( exampleText );
|
|
|
|
if ( lang && lang[1] ) {
|
|
|
|
exampleText = exampleText.replace( lang[0], "" );
|
|
|
|
example.html( exampleText );
|
|
|
|
lang = lang[1];
|
|
|
|
} else {
|
|
|
|
lang = "javascript";
|
|
|
|
}
|
|
|
|
|
|
|
|
if ( lang ) {
|
|
|
|
|
|
|
|
$this
|
|
|
|
.addClass( "sunlight-highlight-" + lang )
|
|
|
|
.addClass( "linenums" )
|
|
|
|
.html( example.html() );
|
|
|
|
|
|
|
|
}
|
|
|
|
} );
|
|
|
|
|
|
|
|
Sunlight.highlightAll( {
|
|
|
|
lineNumbers : true,
|
|
|
|
showMenu : true,
|
|
|
|
enableDoclinks : true
|
|
|
|
} );
|
|
|
|
} );
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!--Navigation and Symbol Display-->
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!--Google Analytics-->
|
|
|
|
|
|
|
|
|
|
|
|
</body>
|
|
|
|
</html>
|