Loading...
Searching...
No Matches
MssqlSqlUtilBase::MssqlDatabase Class Reference

provides the Mssql-specific implementation of the AbstractDatabase interface More...

Inherits SqlUtil::AbstractDatabase.

## Public Member Functions

int | getMaximumPrecision ()
| Returns the maximum precision for numeric or decimal columns.
bool | requiresScale ()
| Returns True if the driver requires a scale to support decimal values in numeric or decimal columns.

## Static Public Member Functions

static string | getCreateSql (list l)
| returns a string that can be used to create the schema in the database
static bool | isSybase (AbstractDatasource ds)
| returns True if the DB is a Sybase database
static auto | tryExecArgs (AbstractDatasource ds, string sql, __7_ softlist< auto > args)
| tries to execute a command so that if an error occurs the current transaction status is not lost
static auto | tryExecRaw (AbstractDatasource ds, string sql)
| tries to execute a command so that if an error occurs the current transaction status is not lost

## Public Attributes

string | default_schema = "dbo"
| default schema for user
bool | is_sybase
| sybase flag
const | MaxPrecision = 38
| Maximum precision.
const | MssqlReclaimSpaceOptions = ReclaimSpaceOptions
| Options for reclaimSpace()
const | MssqlReservedWords = ...
| hash of reserved words
const | MssqlSchemaDescriptionOptions = AbstractDatabase::SchemaDescriptionOptions
| Mssql-specific schema description keys.

## Protected Member Functions

| computeStatisticsImpl (__7_ hash options)
| compute statistics implementation. See SqlUtil::AbstractDatabase::computeStatistics()
string | getCreateSqlImpl (list l)
| returns a string that can be used to create the schema in the database
softint | getCurrentSequenceValueImpl (string name)
| returns the last value issued for the given sequence in the current session
softint | getNextSequenceValueImpl (string name)
| returns the next value in the given sequence
int | getPhysicalSizeImpl ()
| SqlUtil::AbstractDatabase.getPhysicalSize()
hash | getReclaimSpaceOptions ()
| returns driver-specific options to the base abstract class
hash | getSchemaDescriptionOptions ()
| returns driver-specific options to the base abstract class
list< string > | listFunctionsImpl ()
| returns a list of string function names in the database
list< string > | listProceduresImpl ()
| since Mssql only supports functions, this method is identical to listFunctionsImpl()
softlist< string > | listTablesImpl ()
| returns a list of string table names in the database
bool | rebuildIndexImpl (string name, __7_ hash options)
| rebuild index implementation. See SqlUtil::AbstractDatabase::rebuildIndex()
| reclaimSpaceImpl (__7_ hash options)
| reclaim space implementation. See SqlUtil::AbstractDatabase::reclaimSpace()
bool | supportsPackagesImpl ()
| returns True if the database supports packages
bool | supportsSequencesImpl ()
| returns True if the database supports sequences
bool | supportsTypesImpl ()
| returns True if the database supports named types
auto | tryExecArgsImpl (string sql, __7_ softlist< auto > args)
| tries to execute a command so that if an error occurs the current transaction status is not lost
auto | tryExecRawImpl (string sql, __7_ softlist< auto > args)
| tries to execute a command so that if an error occurs the current transaction status is not lost

## Detailed Description

provides the Mssql-specific implementation of the AbstractDatabase interface

## Member Function Documentation

## getMaximumPrecision()

int MssqlSqlUtilBase::MssqlDatabase::getMaximumPrecision | ( |  | ) |

Returns the maximum precision for numeric or decimal columns.

Returns
  -1 means, no maximum

Since
  FreeSqlUtil 1.4.2

## listFunctionsImpl()

list< string > MssqlSqlUtilBase::MssqlDatabase::listFunctionsImpl | ( |  | ) |

protected

returns a list of string function names in the database

The function names will include arguments in parentheses after the names

Returns
  a list of string function names in the database

## listProceduresImpl()

list< string > MssqlSqlUtilBase::MssqlDatabase::listProceduresImpl | ( |  | ) |

protected

since Mssql only supports functions, this method is identical to listFunctionsImpl()

See also
  listFunctionsImpl()

## requiresScale()

bool MssqlSqlUtilBase::MssqlDatabase::requiresScale | ( |  | ) |

Returns True if the driver requires a scale to support decimal values in numeric or decimal columns.

Returns
  True if the driver requires a scale to support decimal values in numeric or decimal columns

Since
  FreeSqlUtil 1.4.2