Determine whether a variable is of the type specified in the function name, eg isNumber
Types available are Null, Undefined, Object, Array, String, Number, Boolean, Function, RegExp, NaN and Infinite
mixed
o
:
Boolean
.isScalar(obj)
Determine whether an object is scalar
Determine whether an object is scalar
mixed
obj
:
Object to test
bool
:
Is object scalar
.type(o)
Get the type of the variable passed
Get the type of the variable passed
mixed
o
:
Object to type check
String
:
Type of the object
Return the output of the parsing of the join condition
String
condition
:
The join condition to evalate
String
:
The parsed/escaped join condition
Driver
driver
:
The driver object for the database in use
void
Run the generated delete query
String
table
:
The table to insert into
[Object
]
where
:
Where clause for delete statement
Function
callback
:
Callback for handling response from the database
void
Closes the database connection for the current adapter
void
Filter matched patterns
Array
array
:
Set of possible matches
Array
or
:
Filtered set of possible matches
Specify the database table to select from
String
tableName
:
The table to use for the current query
QueryBuilder
:
The Query Builder object, for chaining
Get the results of the compiled query
[String
]
table
:
The table to select from
[Number
]
limit
:
A limit for the query
[Number
]
offset
:
An offset for the query
Function
callback
:
A callback for receiving the result
void
Return generated delete query SQL
String
table
:
the name of the table to delete from
[Boolean
]
reset
(default true
)
:
Whether to reset the query builder so another query can be built
String
:
The compiled sql statement
Return generated insert query SQL
String
table
:
the name of the table to insert into
[Boolean
]
reset
(default true
)
:
Whether to reset the query builder so another query can be built
String
:
The compiled sql statement
Return generated select query SQL
[String
]
table
:
the name of the table to retrieve from
[Boolean
]
reset
(default true
)
:
Whether to reset the query builder so another query can be built
String
:
The compiled sql statement
Return generated update query SQL
String
table
:
the name of the table to update
[Boolean
]
reset
(default true
)
:
Whether to reset the query builder so another query can be built
String
:
The compiled sql statement
Group the results by the selected field(s)
QueryBuilder
:
The Query Builder object, for chaining
Ends a logical grouping started with one of the groupStart methods
QueryBuilder
:
The Query Builder object, for chaining
Adds an open paren to the current query for logical grouping
QueryBuilder
:
The Query Builder object, for chaining
Check if the string contains an operator, and if so, return the operator(s). If there are no matches, return null
String
string
:
the string to check
Array
or
:
List of operators
Add a 'having' clause
String
or Object
key
:
The name of the field and the comparision operator, or an object
[String
or Number
]
val
:
The value to compare if the value of key is a string
QueryBuilder
:
The Query Builder object, for chaining
Run the generated insert query
String
table
:
The table to insert into
[Object
]
data
:
Data to insert, if not already added with the 'set' method
Function
callback
:
Callback for handling response from the database
void
Insert multiple sets of rows at a time
String
table
:
The table to insert into
Array
data
:
The array of objects containing data rows to insert
Function
callback
:
Callback for handling database response
void
query.insertBatch('foo',[{id:1,val:'bar'},{id:2,val:'baz'}], callbackFunction);
Add a join clause to the query
String
table
:
The table you are joining
String
cond
:
The join condition.
[String
]
type
(default 'inner'
)
:
The type of join, which defaults to inner
QueryBuilder
:
The Query Builder object, for chaining
Add a 'like/ and like' clause to the query
String
field
:
The name of the field to compare to
String
val
:
The value to compare to
[String
]
pos
(default both
)
:
The placement of the wildcard character(s): before, after, or both
QueryBuilder
:
The Query Builder object, for chaining
Put a limit on the query
QueryBuilder
:
The Query Builder object, for chaining
Add a 'not like/ and not like' clause to the query
String
field
:
The name of the field to compare to
String
val
:
The value to compare to
[String
]
pos
(default both
)
:
The placement of the wildcard character(s): before, after, or both
QueryBuilder
:
The Query Builder object, for chaining
Adds an open paren to the current query for logical grouping, prefixed with 'OR'
QueryBuilder
:
The Query Builder object, for chaining
Add an 'or having' clause
String
or Object
key
:
The name of the field and the comparision operator, or an object
[String
or Number
]
val
:
The value to compare if the value of key is a string
QueryBuilder
:
The Query Builder object, for chaining
Add an 'or like' clause to the query
String
field
:
The name of the field to compare to
String
val
:
The value to compare to
[String
]
pos
(default both
)
:
The placement of the wildcard character(s): before, after, or both
QueryBuilder
:
The Query Builder object, for chaining
Adds an open paren to the current query for logical grouping, prefixed with 'OR NOT'
QueryBuilder
:
The Query Builder object, for chaining
Add an 'or not like' clause to the query
String
field
:
The name of the field to compare to
String
val
:
The value to compare to
[String
]
pos
(default both
)
:
The placement of the wildcard character(s): before, after, or both
QueryBuilder
:
The Query Builder object, for chaining
Set a 'or where' clause
String
or Object
key
:
The name of the field and the comparision operator, or an object
[String
or Number
]
val
:
The value to compare if the value of key is a string
QueryBuilder
:
The Query Builder object, for chaining
Set a 'or where in' clause
QueryBuilder
:
The Query Builder object, for chaining
Field is not null prefixed with 'OR'
String
field
:
The name of the field
QueryBuilder
:
The Query Builder object, for chaining
Field is null prefixed with 'OR'
String
field
:
The name of the field
QueryBuilder
:
The Query Builder object, for chaining
Set a 'or where not in' clause
QueryBuilder
:
The Query Builder object, for chaining
Order the results by the selected field(s)
String
field
:
The field(s) to order by
[String
]
type
(default 'ASC'
)
:
The order direction, ASC or DESC
QueryBuilder
:
The Query Builder object, for chaining
Tokenize the sql into parts for additional processing
String
sql
:
Join sql to parse
Object
:
Join condition components
Parse a where clause to separate functions from values
Driver
driver
:
The current db driver
State
state
:
Query Builder state object
String
:
The parsed/escaped where condition
Reset the object state for a new query
void
Specify rows to select in the query
QueryBuilder
:
The Query Builder object, for chaining
Set values for insertion or updating
QueryBuilder
:
The Query Builder object, for chaining
Run the generated update query
String
table
:
The table to insert into
[Object
]
data
:
Data to insert, if not already added with the 'set' method
Function
callback
:
Callback for handling response from the database
void
Set a 'where' clause
String
or Object
key
:
The name of the field and the comparision operator, or an object
[String
or Number
]
val
:
The value to compare if the value of key is a string
QueryBuilder
:
The Query Builder object, for chaining
Set a 'where in' clause
QueryBuilder
:
The Query Builder object, for chaining
Specify that a field IS NOT NULL
String
field
:
The name so the field that is not to be null
QueryBuilder
:
The Query Builder object, for chaining
Select a field that is Null
String
field
:
The name of the field that has a NULL value
QueryBuilder
:
The Query Builder object, for chaining
Set a 'where not in' clause
QueryBuilder
:
The Query Builder object, for chaining