|
Adodb Dokumentation
V5.14 8 Sept 2011
|

Öffentliche Methoden | |
| ADODB_informix72 () | |
| ServerInfo () | |
| _insertid () | |
| _affectedrows () | |
| BeginTrans () | |
| CommitTrans ($ok=true) | |
| RollbackTrans () | |
| RowLock ($tables, $where, $col='1 as adodbignore') | |
| ErrorMsg () | |
| ErrorNo () | |
| MetaColumns ($table, $normalize=true) | |
| xMetaColumns ($table) | |
| MetaForeignKeys ($table, $owner=false, $upper=false) | |
| Eos. | |
| UpdateBlob ($table, $column, $val, $where, $blobtype= 'BLOB') | |
| BlobDecode ($blobid) | |
| _connect ($argHostname, $argUsername, $argPassword, $argDatabasename) | |
| _pconnect ($argHostname, $argUsername, $argPassword, $argDatabasename) | |
| _query ($sql, $inputarr=false) | |
| _close () | |
Datenfelder | |
| $databaseType = "informix72" | |
| $dataProvider = "informix" | |
| $replaceQuote = "''" | |
| $fmtDate = "'Y-m-d'" | |
| $fmtTimeStamp = "'Y-m-d H:i:s'" | |
| $hasInsertID = true | |
| $hasAffectedRows = true | |
| $substr = 'substr' | |
| $metaTablesSQL = "select tabname,tabtype from systables where tabtype in ('T','V') and owner!='informix'" | |
| $metaColumnsSQL | |
| $metaPrimaryKeySQL | |
| $concat_operator = '||' | |
| $lastQuery = false | |
| $has_insertid = true | |
| $_autocommit = true | |
| $_bindInputArray = true | |
| $sysDate = 'TODAY' | |
| $sysTimeStamp = 'CURRENT' | |
| $cursorType = IFX_SCROLL | |
Definiert in Zeile 22 der Datei adodb-informix72.inc.php.
| MetaColumns | ( | $ | table, |
| $ | normalize = true |
||
| ) |
eos
eos
eos
eos
eos
eos
Definiert in Zeile 150 der Datei adodb-informix72.inc.php.
{
global $ADODB_FETCH_MODE;
$false = false;
if (!empty($this->metaColumnsSQL)) {
$save = $ADODB_FETCH_MODE;
$ADODB_FETCH_MODE = ADODB_FETCH_NUM;
if ($this->fetchMode !== false) $savem = $this->SetFetchMode(false);
$rs = $this->Execute(sprintf($this->metaColumnsSQL,$table));
if (isset($savem)) $this->SetFetchMode($savem);
$ADODB_FETCH_MODE = $save;
if ($rs === false) return $false;
$rspkey = $this->Execute(sprintf($this->metaPrimaryKeySQL,$table)); //Added to get primary key colno items
$retarr = array();
while (!$rs->EOF) { //print_r($rs->fields);
$fld = new ADOFieldObject();
$fld->name = $rs->fields[0];
/* //!eos.
$rs->fields[1] is not the correct adodb type
$rs->fields[2] is not correct max_length, because can include not-null bit
$fld->type = $rs->fields[1];
$fld->primary_key=$rspkey->fields && array_search($rs->fields[4],$rspkey->fields); //Added to set primary key flag
$fld->max_length = $rs->fields[2];*/
$pr=ifx_props($rs->fields[1],$rs->fields[2]);
$fld->type = $pr[0] ;
$fld->primary_key=$rspkey->fields && array_search($rs->fields[4],$rspkey->fields);
$fld->max_length = $pr[1];
$fld->precision = $pr[2] ;
$fld->not_null = $pr[3]=="N";
if (trim($rs->fields[3]) != "AAAAAA 0") {
$fld->has_default = 1;
$fld->default_value = $rs->fields[3];
} else {
$fld->has_default = 0;
}
$retarr[strtolower($fld->name)] = $fld;
$rs->MoveNext();
}
$rs->Close();
$rspkey->Close();
return $retarr;
}
return $false;
}
| $metaColumnsSQL |
"select c.colname, c.coltype, c.collength, d.default,c.colno from syscolumns c, systables t,outer sysdefaults d where c.tabid=t.tabid and d.tabid=t.tabid and d.colno=c.colno and tabname='%s' order by c.colno"
Definiert in Zeile 34 der Datei adodb-informix72.inc.php.
| $metaPrimaryKeySQL |
"select part1,part2,part3,part4,part5,part6,part7,part8 from systables t,sysconstraints s,sysindexes i where t.tabname='%s' and s.tabid=t.tabid and s.constrtype='P' and i.idxname=s.idxname"
Definiert in Zeile 40 der Datei adodb-informix72.inc.php.