\dbQuerySet

Creates the SQL to execute a list of provided SQL queries

Summary

Methods
Properties
Constants
dbObject()
_tag_open()
_tag_cdata()
_tag_close()
create()
destroy()
supportedPlatform()
prefix()
FieldID()
dbQuerySet()
newQuery()
discardQuery()
buildQuery()
addQuery()
prefixQuery()
$parent
$currentElement
$queries
$query
$prefixKey
$prefixMethod
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Properties

$parent

$parent : 

var object Parent

Type

$currentElement

$currentElement : 

var string current element

Type

$queries

$queries : array

Type

array — List of SQL queries

$query

$query : string

Type

string — String used to build of a query line by line

$prefixKey

$prefixKey : string

Type

string — Query prefix key

$prefixMethod

$prefixMethod : boolean

Type

boolean — Auto prefix enable (TRUE)

Methods

dbObject()

dbObject(  $parent,   $attributes = NULL) 

NOP

Parameters

$parent
$attributes

_tag_open()

_tag_open(  $parser,   $tag,   $attributes) 

XML Callback to process start elements. Elements currently processed are: QUERY.

Parameters

$parser
$tag
$attributes

_tag_cdata()

_tag_cdata(  $parser,   $cdata) 

XML Callback to process CDATA elements

Parameters

$parser
$cdata

_tag_close()

_tag_close(  $parser,   $tag) 

XML Callback to process end elements

Parameters

$parser
$tag

create()

create(object  $xmls) : array

Creates and returns the current query set

Parameters

object $xmls

adoSchema object

Returns

array —

Query set

destroy()

destroy() 

Destroys the object

supportedPlatform()

supportedPlatform(string  $platform = NULL) : boolean

Checks whether the specified RDBMS is supported by the current database object or its ranking ancestor.

Parameters

string $platform

RDBMS platform name (from ADODB platform list).

Returns

boolean —

TRUE if RDBMS is supported; otherwise returns FALSE.

prefix()

prefix(string  $name = '') : string

Returns the prefix set by the ranking ancestor of the database object.

Parameters

string $name

Prefix string.

Returns

string —

Prefix.

FieldID()

FieldID(string  $field) : string

Extracts a field ID from the specified field.

Parameters

string $field

Field.

Returns

string —

Field ID.

dbQuerySet()

dbQuerySet(object  $parent, array  $attributes = NULL) 

Initializes the query set.

Parameters

object $parent

Parent object

array $attributes

Attributes

newQuery()

newQuery() : boolean

Re-initializes the query.

Returns

boolean —

TRUE

discardQuery()

discardQuery() : boolean

Discards the existing query.

Returns

boolean —

TRUE

buildQuery()

buildQuery(  $sql = NULL) : string

Appends a line to a query that is being built line by line

Parameters

$sql

Returns

string —

SQL query string.

addQuery()

addQuery() : string

Adds a completed query to the query list

Returns

string —

SQL of added query

prefixQuery()

prefixQuery(string  $regex, string  $query, string  $prefix = NULL) : string

Rebuilds the query with the prefix attached to any objects

Parameters

string $regex

Regex used to add prefix

string $query

SQL query string

string $prefix

Prefix to be appended to tables, indices, etc.

Returns

string —

Prefixed SQL query string.