Öffentliche Methoden | |
GetCommentSQL ($table, $col) | |
in other words, we use a text area for editting. Mehr ... | |
SetCommentSQL ($table, $col, $cmt) | |
MetaTables () | |
MetaColumns ($tab, $upper=true, $schema=false) | |
MetaPrimaryKeys ($tab, $owner=false, $intkey=false) | |
MetaIndexes ($table, $primary=false, $owner=false) | |
MetaType ($t, $len=-1, $fieldobj=false) | |
NameQuote ($name=NULL, $allowBrackets=false) | |
TableName ($name) | |
ExecuteSQLArray ($sql, $continueOnError=true) | |
ActualType ($meta) | |
CreateDatabase ($dbname, $options=false) | |
CreateIndexSQL ($idxname, $tabname, $flds, $idxoptions=false) | |
DropIndexSQL ($idxname, $tabname=NULL) | |
SetSchema ($schema) | |
AddColumnSQL ($tabname, $flds) | |
AlterColumnSQL ($tabname, $flds, $tableflds='', $tableoptions='') | |
RenameColumnSQL ($tabname, $oldcolumn, $newcolumn, $flds='') | |
DropColumnSQL ($tabname, $flds, $tableflds='', $tableoptions='') | |
DropTableSQL ($tabname) | |
RenameTableSQL ($tabname, $newname) | |
CreateTableSQL ($tabname, $flds, $tableoptions=array()) | |
_GenFields ($flds, $widespacing=false) | |
_GetSize ($ftype, $ty, $fsize, $fprec) | |
_CreateSuffix ($fname, &$ftype, $fnotnull, $fdefault, $fautoinc, $fconstraint, $funsigned) | |
_IndexSQL ($idxname, $tabname, $flds, $idxoptions) | |
_DropAutoIncrement ($tabname) | |
_TableSQL ($tabname, $lines, $pkey, $tableoptions) | |
_Triggers ($tabname, $taboptions) | |
_Options ($opts) | |
_getSizePrec ($size) | |
ChangeTableSQL ($tablename, $flds, $tableoptions=false, $dropOldFlds=false) | |
Datenfelder | |
$connection | |
$debug = false | |
$dropTable = 'DROP TABLE %s' | |
$renameTable = 'RENAME TABLE %s TO %s' | |
$dropIndex = 'DROP INDEX %s' | |
$addCol = ' ADD' | |
$alterCol = ' ALTER COLUMN' | |
$dropCol = ' DROP COLUMN' | |
$renameColumn = 'ALTER TABLE %s RENAME COLUMN %s TO %s' | |
$nameRegex = '\w' | |
$nameRegexBrackets = 'a-zA-Z0-9_\(\)' | |
$schema = false | |
$serverInfo = array() | |
$autoIncrement = false | |
$dataProvider | |
$invalidResizeTypes4 = array('CLOB','BLOB','TEXT','DATE','TIME') | |
$blobSize = 100 | |
Definiert in Zeile 164 der Datei adodb-datadict.inc.php.
_CreateSuffix | ( | $fname, | |
& | $ftype, | ||
$fnotnull, | |||
$fdefault, | |||
$fautoinc, | |||
$fconstraint, | |||
$funsigned | |||
) |
Definiert in Zeile 819 der Datei adodb-datadict.inc.php.
Wird benutzt von _GenFields().
_DropAutoIncrement | ( | $tabname) |
Definiert in Zeile 857 der Datei adodb-datadict.inc.php.
Wird benutzt von _TableSQL().
_GenFields | ( | $flds, | |
$widespacing = false |
|||
) |
Definiert in Zeile 595 der Datei adodb-datadict.inc.php.
Benutzt _array_change_key_case(), _CreateSuffix(), _GetSize(), ActualType(), Lens_ParseArgs() und NameQuote().
Wird benutzt von ADODB2_sybase\AddColumnSQL(), ADODB2_sapdb\AddColumnSQL(), ADODB2_mssql\AddColumnSQL(), ADODB2_oci8\AddColumnSQL(), ADODB2_postgres\AddColumnSQL(), ADODB2_mssqlnative\AddColumnSQL(), AddColumnSQL(), ADODB2_sybase\AlterColumnSQL(), ADODB2_sapdb\AlterColumnSQL(), ADODB2_oci8\AlterColumnSQL(), ADODB2_postgres\AlterColumnSQL(), AlterColumnSQL(), ADODB2_db2\ChangeTableSQL(), ChangeTableSQL(), CreateTableSQL() und RenameColumnSQL().
_GetSize | ( | $ftype, | |
$ty, | |||
$fsize, | |||
$fprec | |||
) |
GENERATE THE SIZE PART OF THE DATATYPE $ftype is the actual type $ty is the type defined originally in the DDL
Definiert in Zeile 807 der Datei adodb-datadict.inc.php.
Wird benutzt von _GenFields().
_getSizePrec | ( | $size) |
Definiert in Zeile 919 der Datei adodb-datadict.inc.php.
Wird benutzt von ChangeTableSQL().
_IndexSQL | ( | $idxname, | |
$tabname, | |||
$flds, | |||
$idxoptions | |||
) |
Definiert in Zeile 828 der Datei adodb-datadict.inc.php.
Wird benutzt von CreateIndexSQL().
_Options | ( | $opts) |
Sanitize options, so that array elements with no keys are promoted to keys
Definiert in Zeile 907 der Datei adodb-datadict.inc.php.
Wird benutzt von ADODB2_firebird\CreateDatabase(), ADODB2_oci8\CreateDatabase(), CreateDatabase(), CreateIndexSQL() und CreateTableSQL().
_TableSQL | ( | $tabname, | |
$lines, | |||
$pkey, | |||
$tableoptions | |||
) |
Definiert in Zeile 862 der Datei adodb-datadict.inc.php.
Benutzt _DropAutoIncrement().
Wird benutzt von CreateTableSQL().
_Triggers | ( | $tabname, | |
$taboptions | |||
) |
GENERATE TRIGGERS IF NEEDED used when table has auto-incrementing field that is emulated using triggers
Definiert in Zeile 899 der Datei adodb-datadict.inc.php.
Wird benutzt von CreateTableSQL().
ActualType | ( | $meta) |
Returns the actual type given a character code.
C: varchar X: CLOB (character large object) or largest varchar size if CLOB is not supported C2: Multibyte varchar X2: Multibyte CLOB
B: BLOB (binary large object)
D: Date T: Date-time L: Integer field suitable for storing booleans (0 or 1) I: Integer F: Floating point number N: Numeric or decimal number
Definiert in Zeile 407 der Datei adodb-datadict.inc.php.
Wird benutzt von _GenFields().
AddColumnSQL | ( | $tabname, | |
$flds | |||
) |
Definiert in Zeile 452 der Datei adodb-datadict.inc.php.
Benutzt _GenFields() und TableName().
AlterColumnSQL | ( | $tabname, | |
$flds, | |||
$tableflds = '' , |
|||
$tableoptions = '' |
|||
) |
Change the definition of one column
As some DBM's can't do that on there own, you need to supply the complete defintion of the new table, to allow, recreating the table and copying the content over to the new table
string | $tabname | table-name |
string | $flds | column-name and type for the changed column |
string | $tableflds,='' | complete defintion of the new table, eg. for postgres, default '' |
array/string | $tableoptions='' options for the new table see CreateTableSQL, default '' |
Definiert in Zeile 483 der Datei adodb-datadict.inc.php.
Benutzt _GenFields() und TableName().
ChangeTableSQL | ( | $tablename, | |
$flds, | |||
$tableoptions = false , |
|||
$dropOldFlds = false |
|||
) |
"Florian Buzin [ easywe ]" <florian.buzin::easywe.de>
This function changes/adds new fields to your table. You don't have to know if the col is new or not. It will check on its own.
Definiert in Zeile 939 der Datei adodb-datadict.inc.php.
Benutzt _GenFields(), _getSizePrec(), CreateTableSQL(), Lens_ParseArgs(), MetaColumns(), MetaType() und TableName().
CreateDatabase | ( | $dbname, | |
$options = false |
|||
) |
Definiert in Zeile 412 der Datei adodb-datadict.inc.php.
Benutzt _Options() und NameQuote().
CreateIndexSQL | ( | $idxname, | |
$tabname, | |||
$flds, | |||
$idxoptions = false |
|||
) |
Definiert in Zeile 428 der Datei adodb-datadict.inc.php.
Benutzt _IndexSQL(), _Options(), NameQuote() und TableName().
Wird benutzt von ADODB2_postgres\_recreate_copy_table().
CreateTableSQL | ( | $tabname, | |
$flds, | |||
$tableoptions = array() |
|||
) |
Generate the SQL to create table. Returns an array of sql strings.
Definiert in Zeile 563 der Datei adodb-datadict.inc.php.
Benutzt _GenFields(), _Options(), _TableSQL(), _Triggers() und TableName().
Wird benutzt von ADODB2_postgres\_recreate_copy_table(), ADODB2_db2\ChangeTableSQL() und ChangeTableSQL().
DropColumnSQL | ( | $tabname, | |
$flds, | |||
$tableflds = '' , |
|||
$tableoptions = '' |
|||
) |
Drop one column
Some DBM's can't do that on there own, you need to supply the complete defintion of the new table, to allow, recreating the table and copying the content over to the new table
string | $tabname | table-name |
string | $flds | column-name and type for the changed column |
string | $tableflds,='' | complete defintion of the new table, eg. for postgres, default '' |
array/string | $tableoptions='' options for the new table see CreateTableSQL, default '' |
Definiert in Zeile 538 der Datei adodb-datadict.inc.php.
Benutzt NameQuote() und TableName().
Wird benutzt von ADODB2_postgres\DropColumnSQL().
DropIndexSQL | ( | $idxname, | |
$tabname = NULL |
|||
) |
Definiert in Zeile 442 der Datei adodb-datadict.inc.php.
Benutzt NameQuote() und TableName().
DropTableSQL | ( | $tabname) |
Definiert in Zeile 550 der Datei adodb-datadict.inc.php.
Benutzt TableName().
Wird benutzt von ADODB2_postgres\DropTableSQL().
ExecuteSQLArray | ( | $sql, | |
$continueOnError = true |
|||
) |
Definiert in Zeile 370 der Datei adodb-datadict.inc.php.
Benutzt $connection und $ok.
GetCommentSQL | ( | $table, | |
$col | |||
) |
in other words, we use a text area for editting.
any varchar/char field this size or greater is treated as a blob
Definiert in Zeile 184 der Datei adodb-datadict.inc.php.
MetaColumns | ( | $tab, | |
$upper = true , |
|||
$schema = false |
|||
) |
Definiert in Zeile 200 der Datei adodb-datadict.inc.php.
Benutzt $schema und TableName().
Wird benutzt von ADODB2_postgres\_recreate_copy_table(), ADODB2_postgres\AlterColumnSQL(), ADODB2_db2\ChangeTableSQL() und ChangeTableSQL().
MetaIndexes | ( | $table, | |
$primary = false , |
|||
$owner = false |
|||
) |
Definiert in Zeile 212 der Datei adodb-datadict.inc.php.
Benutzt TableName().
Wird benutzt von ADODB2_postgres\_recreate_copy_table().
MetaPrimaryKeys | ( | $tab, | |
$owner = false , |
|||
$intkey = false |
|||
) |
Definiert in Zeile 206 der Datei adodb-datadict.inc.php.
Benutzt TableName().
MetaTables | ( | ) |
Definiert in Zeile 194 der Datei adodb-datadict.inc.php.
MetaType | ( | $t, | |
$len = -1 , |
|||
$fieldobj = false |
|||
) |
Definiert in Zeile 218 der Datei adodb-datadict.inc.php.
Wird benutzt von ChangeTableSQL().
NameQuote | ( | $name = NULL , |
|
$allowBrackets = false |
|||
) |
Definiert in Zeile 332 der Datei adodb-datadict.inc.php.
Wird benutzt von _GenFields(), CreateDatabase(), CreateIndexSQL(), ADODB2_sapdb\DropColumnSQL(), ADODB2_oci8\DropColumnSQL(), ADODB2_mssqlnative\DropColumnSQL(), DropColumnSQL(), DropIndexSQL(), RenameColumnSQL() und TableName().
RenameColumnSQL | ( | $tabname, | |
$oldcolumn, | |||
$newcolumn, | |||
$flds = '' |
|||
) |
Rename one column
Some DBM's can only do this together with changeing the type of the column (even if that stays the same, eg. mysql)
string | $tabname | table-name |
string | $oldcolumn | column-name to be renamed |
string | $newcolumn | new column-name |
string | $flds,='' | complete column-defintion-string like for AddColumnSQL, only used by mysql atm., default='' |
Definiert in Zeile 514 der Datei adodb-datadict.inc.php.
Benutzt _GenFields(), NameQuote() und TableName().
RenameTableSQL | ( | $tabname, | |
$newname | |||
) |
Definiert in Zeile 555 der Datei adodb-datadict.inc.php.
Benutzt TableName().
SetCommentSQL | ( | $table, | |
$col, | |||
$cmt | |||
) |
Definiert in Zeile 189 der Datei adodb-datadict.inc.php.
SetSchema | ( | $schema) |
Definiert in Zeile 447 der Datei adodb-datadict.inc.php.
Benutzt $schema.
TableName | ( | $name) |
Definiert in Zeile 361 der Datei adodb-datadict.inc.php.
Benutzt NameQuote().
Wird benutzt von ADODB2_sybase\AddColumnSQL(), ADODB2_sapdb\AddColumnSQL(), ADODB2_mssql\AddColumnSQL(), ADODB2_postgres\AddColumnSQL(), ADODB2_mssqlnative\AddColumnSQL(), AddColumnSQL(), ADODB2_sybase\AlterColumnSQL(), ADODB2_sapdb\AlterColumnSQL(), ADODB2_postgres\AlterColumnSQL(), AlterColumnSQL(), ADODB2_db2\ChangeTableSQL(), ChangeTableSQL(), CreateIndexSQL(), CreateTableSQL(), ADODB2_sybase\DropColumnSQL(), ADODB2_sapdb\DropColumnSQL(), ADODB2_mssql\DropColumnSQL(), ADODB2_mssqlnative\DropColumnSQL(), DropColumnSQL(), ADODB2_postgres\DropIndexSQL(), DropIndexSQL(), DropTableSQL(), MetaColumns(), MetaIndexes(), MetaPrimaryKeys(), RenameColumnSQL(), ADODB2_postgres\RenameTableSQL() und RenameTableSQL().
$addCol = ' ADD' |
Definiert in Zeile 170 der Datei adodb-datadict.inc.php.
$alterCol = ' ALTER COLUMN' |
Definiert in Zeile 171 der Datei adodb-datadict.inc.php.
$autoIncrement = false |
Definiert in Zeile 178 der Datei adodb-datadict.inc.php.
$blobSize = 100 |
Definiert in Zeile 181 der Datei adodb-datadict.inc.php.
$connection |
Definiert in Zeile 165 der Datei adodb-datadict.inc.php.
Wird benutzt von ExecuteSQLArray().
$dataProvider |
Definiert in Zeile 179 der Datei adodb-datadict.inc.php.
$debug = false |
Definiert in Zeile 166 der Datei adodb-datadict.inc.php.
$dropCol = ' DROP COLUMN' |
Definiert in Zeile 172 der Datei adodb-datadict.inc.php.
$dropIndex = 'DROP INDEX %s' |
Definiert in Zeile 169 der Datei adodb-datadict.inc.php.
$dropTable = 'DROP TABLE %s' |
Definiert in Zeile 167 der Datei adodb-datadict.inc.php.
$invalidResizeTypes4 = array('CLOB','BLOB','TEXT','DATE','TIME') |
Definiert in Zeile 180 der Datei adodb-datadict.inc.php.
$nameRegex = '\w' |
Definiert in Zeile 174 der Datei adodb-datadict.inc.php.
$nameRegexBrackets = 'a-zA-Z0-9_\(\)' |
Definiert in Zeile 175 der Datei adodb-datadict.inc.php.
$renameColumn = 'ALTER TABLE %s RENAME COLUMN %s TO %s' |
Definiert in Zeile 173 der Datei adodb-datadict.inc.php.
$renameTable = 'RENAME TABLE %s TO %s' |
Definiert in Zeile 168 der Datei adodb-datadict.inc.php.
$schema = false |
Definiert in Zeile 176 der Datei adodb-datadict.inc.php.
Wird benutzt von MetaColumns(), ADODB2_postgres\RenameTableSQL() und SetSchema().
$serverInfo = array() |
Definiert in Zeile 177 der Datei adodb-datadict.inc.php.