[ Index ]

PHP Cross Reference of Moodle 1.9.3 [Build 15-Oct-2008]

title

Body

[close]

/lib/xmldb/classes/generators/mssql/ -> mssql.class.php (summary)

(no description)

File Size: 568 lines (27 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

XMLDBmssql:: (17 methods):
  XMLDBmssql()
  getTypeSQL()
  getEnumExtraSQL()
  getDropFieldSQL()
  getRenameFieldSQL()
  getRenameFieldExtraSQL()
  getRenameTableExtraSQL()
  getAlterFieldSQL()
  getModifyDefaultSQL()
  getCreateEnumSQL()
  getDropEnumSQL()
  getCreateDefaultSQL()
  getDropDefaultSQL()
  getDefaultConstraintName()
  getCheckConstraintsFromDB()
  isNameInUse()
  getReservedWords()


Class: XMLDBmssql  - X-Ref

XMLDBmssql()   X-Ref
Creates one new XMLDBmssql


getTypeSQL($xmldb_type, $xmldb_length=null, $xmldb_decimals=null)   X-Ref
Given one XMLDB Type, lenght and decimals, returns the DB proper SQL type


getEnumExtraSQL($xmldb_table, $xmldb_field)   X-Ref
Returns the code needed to create one enum for the xmldb_table and xmldb_field passes


getDropFieldSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to drop the field from the table
MSSQL overwrites the standard sentence because it needs to do some extra work dropping the default and
check constraints


getRenameFieldSQL($xmldb_table, $xmldb_field, $newname)   X-Ref
Given one correct XMLDBField and the new name, returns the SQL statements
to rename it (inside one array)
MSSQL is special, so we overload the function here. It needs to
drop the constraints BEFORE renaming the field


getRenameFieldExtraSQL($xmldb_table, $xmldb_field, $newname)   X-Ref
Returns the code (array of statements) needed to execute extra statements on field rename


getRenameTableExtraSQL($xmldb_table, $newname)   X-Ref
Returns the code (array of statements) needed to execute extra statements on table rename


getAlterFieldSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to alter the field in the table


getModifyDefaultSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to modify the default of the field in the table


getCreateEnumSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to create its enum
(usually invoked from getModifyEnumSQL()


getDropEnumSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to drop its enum
(usually invoked from getModifyEnumSQL()


getCreateDefaultSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to create its default
(usually invoked from getModifyDefaultSQL()


getDropDefaultSQL($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, return the SQL statements needded to drop its default
(usually invoked from getModifyDefaultSQL()


getDefaultConstraintName($xmldb_table, $xmldb_field)   X-Ref
Given one XMLDBTable and one XMLDBField, returns the name of its default constraint in DB
or false if not found
This function should be considered internal and never used outside from generator


getCheckConstraintsFromDB($xmldb_table, $xmldb_field = null)   X-Ref
Given one XMLDBTable returns one array with all the check constrainsts
in the table (fetched from DB)
Optionally the function allows one xmldb_field to be specified in
order to return only the check constraints belonging to one field.
Each element contains the name of the constraint and its description
If no check constraints are found, returns an empty array


isNameInUse($object_name, $type, $table_name)   X-Ref
Given one object name and it's type (pk, uk, fk, ck, ix, uix, seq, trg)
return if such name is currently in use (true) or no (false)
(invoked from getNameForObject()


getReservedWords()   X-Ref
Returns an array of reserved words (lowercase) for this DB




Generated: Wed Jan 14 11:33:29 2009 Cross-referenced by PHPXref 0.7