[ Index ]
 

Code source de vtiger CRM 5.0.2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/adodb/datadict/ -> datadict-postgres.inc.php (sommaire)

(pas de description)

Poids: 371 lignes (12 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 0 fichiers

Définit 1 class

ADODB2_postgres:: (11 méthodes):
  MetaType()
  ActualType()
  AddColumnSQL()
  AlterColumnSQL()
  DropColumnSQL()
  _recreate_copy_table()
  DropTableSQL()
  _CreateSuffix()
  _DropAutoIncrement()
  _IndexSQL()
  _GetSize()


Classe: ADODB2_postgres  - X-Ref

MetaType($t,$len=-1,$fieldobj=false)   X-Ref
Pas de description

ActualType($meta)   X-Ref
Pas de description

AddColumnSQL($tabname, $flds)   X-Ref
Adding a new Column

reimplementation of the default function as postgres does NOT allow to set the default in the same statement

param: string $tabname table-name
param: string $flds column-names and types for the changed columns
return: array with SQL strings

AlterColumnSQL($tabname, $flds, $tableflds='',$tableoptions='')   X-Ref
Change the definition of one column

Postgres can't do that on it's 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
param: string $tabname table-name
param: string $flds column-name and type for the changed column
param: string $tableflds complete defintion of the new table, eg. for postgres, default ''
param: array/ $tableoptions options for the new table see CreateTableSQL, default ''
return: array with SQL strings

DropColumnSQL($tabname, $flds, $tableflds='',$tableoptions='')   X-Ref
Drop one column

Postgres < 7.3 can't do that on it's 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
param: string $tabname table-name
param: string $flds column-name and type for the changed column
param: string $tableflds complete defintion of the new table, eg. for postgres, default ''
param: array/ $tableoptions options for the new table see CreateTableSQL, default ''
return: array with SQL strings

_recreate_copy_table($tabname,$dropflds,$tableflds,$tableoptions='')   X-Ref
Save the content into a temp. table, drop and recreate the original table and copy the content back in

We also take care to set the values of the sequenz and recreate the indexes.
All this is done in a transaction, to not loose the content of the table, if something went wrong!
param: string $tabname table-name
param: string $dropflds column-names to drop
param: string $tableflds complete defintion of the new table, eg. for postgres
param: array/string $tableoptions options for the new table see CreateTableSQL, default ''
return: array with SQL strings

DropTableSQL($tabname)   X-Ref
Pas de description

_CreateSuffix($fname, &$ftype, $fnotnull,$fdefault,$fautoinc,$fconstraint)   X-Ref
Pas de description

_DropAutoIncrement($tabname)   X-Ref
Pas de description

_IndexSQL($idxname, $tabname, $flds, $idxoptions)   X-Ref
Pas de description

_GetSize($ftype, $ty, $fsize, $fprec)   X-Ref
Pas de description



Généré le : Sun Feb 25 10:22:19 2007 par Balluche grâce à PHPXref 0.7