Qore XdbcFirebirdSqlUtilBase Module Reference 0.1
Loading...
Searching...
No Matches
XdbcFirebirdSqlUtilBase::XdbcFirebirdTable Class Reference

provides the XdbcFirebird-specific implementation of the AbstractTable interface More...

#include <XdbcFirebirdSqlUtilBase.qm.dox.h>

Inheritance diagram for XdbcFirebirdSqlUtilBase::XdbcFirebirdTable:
[legend]

Public Member Methods

string getColumnSqlName (string col)
 Returns the column name for use in SQL strings. More...
 
list< string > getColumnSqlNames (softlist< auto > cols)
 returns a list of column names for use in SQL strings; subclasses can process the argument list in case a column name is a reserved word
 
hash< auto > getExpressionMap ()
 Returns the expression map for Firebird.
 
string getSqlName ()
 returns the name of the table to be used in SQL (with a possible qualifiers for schema, etc)
 
hash< auto > getWhereOperatorMap ()
 returns the "where" operator map for Firebird
 
bool hasArrayBind ()
 returns False because the xdbcfirebird driver does not support array binds / bulk DML
 
bool hasReturningImpl ()
 returns True if the current database driver supports the "returning" clause in insert statements, False if not
 

Static Public Member Methods

static *string getSqlValue (auto v)
 returns a string for use in SQL queries representing the DB-specific value of the argument More...
 

Public Attributes

const FirebirdExpressionMap
 Firebird Expression map.
 
const FirebirdOpMap
 Firebird operator map.
 
const QoreTypeMap = ...
 maps qore type names to XdbcFirebird type names
 
const XdbcFirebirdCopMap = ...
 column operator specializations for XdbcFirebird
 
const XdbcFirebirdTypeMap
 maps xdbcfirebird type names to type configurations
 

Private Member Methods

bool asteriskRequiresPrefix ()
 returns True if the database requires a wildcard "*" to be prefixed with the table name when it appears with other column arguments in a select statement
 
bool constraintsLinkedToIndexesImpl ()
 returns True if the database links constraints to indexes (ie dropping the constraint drops the index, etc)
 
 copyImpl (AbstractTable old)
 db-specific copy actions
 
 doSelectLimitOnlyUnlockedImpl (reference< hash< QueryInfo > > info, reference< string > sql)
 processes a string for use in SQL select statements when there is a "limit" argument, but no "orderby" or "offset" arguments
 
 doSelectOrderByWithOffsetSqlUnlockedImpl (reference< hash< QueryInfo > > info, reference< string > sql, list< auto > coll)
 processes a string for use in SQL select statements when there is an "order by" and "offset" argument
 
hash getColumnOperatorMapImpl ()
 returns the column operator map for this object
 
AbstractDataProviderType getNumericTypeImpl (string native_type, bool nullable, *hash< auto > options)
 returns the type for number / numeric columns for the database so that data conversions can be handled
 
AbstractSavepointHelper getSavepointHelperImpl (*string savepoint)
 get DB-specific savepoint helper More...
 
*string getSqlValueImpl (auto v)
 returns a string for use in SQL queries representing the DB-specific value of the argument More...
 
bool isDuplicateRowErrorImpl (hash< ExceptionInfo > ex)
 Returns True if the exception was raised because of a duplicate row / key error. More...
 
bool supportsTablespacesImpl ()
 returns True if the database support tablespaces
 
bool uniqueIndexCreatesConstraintImpl ()
 returns True if the database automatically creates a unique constraint when a unique index is created (ex: xdbcfirebird)
 

Static Private Member Methods

static *string getSqlValueIntern (auto v)
 returns a string for use in SQL queries representing the DB-specific value of the argument More...
 

Detailed Description

provides the XdbcFirebird-specific implementation of the AbstractTable interface

Member Function Documentation

◆ getColumnSqlName()

string XdbcFirebirdSqlUtilBase::XdbcFirebirdTable::getColumnSqlName ( string  col)

Returns the column name for use in SQL strings.

Subclasses can return a special string in case the column name is a reserved word

Firebird requires column names to be enclosed in double quotes

◆ getSavepointHelperImpl()

AbstractSavepointHelper XdbcFirebirdSqlUtilBase::XdbcFirebirdTable::getSavepointHelperImpl ( *string  savepoint)
privatevirtual

get DB-specific savepoint helper

Parameters
savepointthe savepoint string, if not given a unique savepoint string will be generated
Since
SqlUtil 1.6

Implements SqlUtil::AbstractTable.

◆ getSqlValue()

static *string XdbcFirebirdSqlUtilBase::XdbcFirebirdTable::getSqlValue ( auto  v)
static

returns a string for use in SQL queries representing the DB-specific value of the argument

Example:
string str = table.getSqlValue(date);
Parameters
vthe value to convert to an SQL value
Returns
a string representing the value usable in SQL strings for the given database driver
Exceptions
VALUE-ERRORthe given value cannot be converted to an SQL string (missing rules for value)

◆ getSqlValueImpl()

*string XdbcFirebirdSqlUtilBase::XdbcFirebirdTable::getSqlValueImpl ( auto  v)
privatevirtual

returns a string for use in SQL queries representing the DB-specific value of the argument

returns NOTHING if the type cannot be converted to an SQL string

Implements SqlUtil::AbstractTable.

◆ getSqlValueIntern()

static *string XdbcFirebirdSqlUtilBase::XdbcFirebirdTable::getSqlValueIntern ( auto  v)
staticprivate

returns a string for use in SQL queries representing the DB-specific value of the argument

returns NOTHING if the type cannot be converted to an SQL string

◆ isDuplicateRowErrorImpl()

bool XdbcFirebirdSqlUtilBase::XdbcFirebirdTable::isDuplicateRowErrorImpl ( hash< ExceptionInfo >  ex)
privatevirtual

Returns True if the exception was raised because of a duplicate row / key error.

Since
XdbcFirebirdSqlUtilBase 1.4.2

Implements SqlUtil::AbstractTable.