Ubiquity 2.5.2
php rapid development framework
Loading...
Searching...
No Matches
SqlUtils Class Reference

SQL utilities. More...

Static Public Member Functions

static getWhere ($keyAndValues)
 
static getWherePK ($pkKeyAndValues)
 
static getMultiWhere ($values, $field)
 
static getSearchWhere ($likeOp, $fields, $value, $jokerBefore='%', $jokerAfter='%')
 
static getInsertFields ($keyAndValues)
 
static getInsertFieldsValues ($keyAndValues)
 
static getUpdateFieldsKeyAndParams ($keyAndValues)
 
static getUpdateFieldsKeyAndValues ($keyAndValues)
 
static checkWhere ($condition)
 
static checkWhereParams ($condition, &$params=[])
 
static getCondition ($keyValues, $classname=null, $separator=' AND ')
 
static getFieldList ($fields, $tableName=false)
 

Static Public Attributes

static $quote = '`'
 

Static Private Member Functions

static getParameters ($keyAndValues)
 
static getQuotedKeys ($keyAndValues)
 

Detailed Description

SQL utilities.

Author
jc
Version
1.0.4

Definition at line 13 of file SqlUtils.php.

Member Function Documentation

◆ checkWhere()

static checkWhere (   $condition)
static

Definition at line 88 of file SqlUtils.php.

◆ checkWhereParams()

static checkWhereParams (   $condition,
$params = [] 
)
static

Definition at line 95 of file SqlUtils.php.

◆ getCondition()

static getCondition (   $keyValues,
  $classname = null,
  $separator = ' AND ' 
)
static

Definition at line 109 of file SqlUtils.php.

◆ getFieldList()

static getFieldList (   $fields,
  $tableName = false 
)
static
Parameters
array | string$fields
boolean | string$tableName
Returns
string

Definition at line 135 of file SqlUtils.php.

◆ getInsertFields()

static getInsertFields (   $keyAndValues)
static

Definition at line 64 of file SqlUtils.php.

◆ getInsertFieldsValues()

static getInsertFieldsValues (   $keyAndValues)
static

Definition at line 68 of file SqlUtils.php.

◆ getMultiWhere()

static getMultiWhere (   $values,
  $field 
)
static

Definition at line 48 of file SqlUtils.php.

◆ getParameters()

static getParameters (   $keyAndValues)
staticprivate

Definition at line 16 of file SqlUtils.php.

◆ getQuotedKeys()

static getQuotedKeys (   $keyAndValues)
staticprivate

Definition at line 24 of file SqlUtils.php.

◆ getSearchWhere()

static getSearchWhere (   $likeOp,
  $fields,
  $value,
  $jokerBefore = '%',
  $jokerAfter = '%' 
)
static

Definition at line 56 of file SqlUtils.php.

◆ getUpdateFieldsKeyAndParams()

static getUpdateFieldsKeyAndParams (   $keyAndValues)
static

Definition at line 72 of file SqlUtils.php.

◆ getUpdateFieldsKeyAndValues()

static getUpdateFieldsKeyAndValues (   $keyAndValues)
static

Definition at line 80 of file SqlUtils.php.

◆ getWhere()

static getWhere (   $keyAndValues)
static

Definition at line 32 of file SqlUtils.php.

◆ getWherePK()

static getWherePK (   $pkKeyAndValues)
static

Definition at line 40 of file SqlUtils.php.

Field Documentation

◆ $quote

$quote = '`'
static

Definition at line 14 of file SqlUtils.php.


The documentation for this class was generated from the following file: