/*
* Parent class of all ADODB objects.
*
- * $Id: ADODB_base.php,v 1.21 2005/05/25 04:33:23 chriskl Exp $
+ * $Id: ADODB_base.php,v 1.22 2007/01/10 02:01:17 soranzo Exp $
*/
include_once('./libraries/errorhandler.inc.php');
if (!$rs) return $this->conn->ErrorNo();
elseif ($rs->RecordCount() == 0) return -1;
- return $rs->f[$field];
+ return $rs->fields[$field];
}
/**
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres71.php,v 1.74 2005/10/18 03:45:16 chriskl Exp $
+ * $Id: Postgres71.php,v 1.75 2007/01/10 02:01:17 soranzo Exp $
*/
// @@@ THOUGHT: What about inherits? ie. use of ONLY???
// Get the minimum value of the sequence
$seq = $this->getSequence($sequence);
if ($seq->recordCount() != 1) return -1;
- $minvalue = $seq->f['min_value'];
+ $minvalue = $seq->fields['min_value'];
/* This double-cleaning is deliberate */
$this->fieldClean($sequence);
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres72.php,v 1.87 2006/12/28 05:03:41 xzilla Exp $
+ * $Id: Postgres72.php,v 1.88 2007/01/10 02:01:17 soranzo Exp $
*/
$rs = $this->selectSet($sql);
if ($rs->recordCount() != 1) return -99;
else {
- $rs->f['relhasoids'] = $this->phpBool($rs->f['relhasoids']);
- return $rs->f['relhasoids'];
+ $rs->fields['relhasoids'] = $this->phpBool($rs->fields['relhasoids']);
+ return $rs->fields['relhasoids'];
}
}
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres73.php,v 1.160 2006/09/30 17:30:56 xzilla Exp $
+ * $Id: Postgres73.php,v 1.161 2007/01/10 02:01:17 soranzo Exp $
*/
// @@@ THOUGHT: What about inherits? ie. use of ONLY???
$rs = $this->selectSet($sql);
if ($rs->recordCount() != 1) return -99;
else {
- $rs->f['relhasoids'] = $this->phpBool($rs->f['relhasoids']);
- return $rs->f['relhasoids'];
+ $rs->fields['relhasoids'] = $this->phpBool($rs->fields['relhasoids']);
+ return $rs->fields['relhasoids'];
}
}
else {
$temp = array();
while (!$rs->EOF) {
- $temp[$rs->f['attnum']] = $rs->f['attname'];
+ $temp[$rs->fields['attnum']] = $rs->fields['attname'];
$rs->moveNext();
}
return $temp;
}
// Otherwise find the names of the keys
else {
- $attnames = $this->getAttributeNames($oldtable, explode(' ', $rs->f['indkey']));
+ $attnames = $this->getAttributeNames($oldtable, explode(' ', $rs->fields['indkey']));
if (!is_array($attnames)) {
$this->rollbackTransaction();
return -1;
// Get the minimum value of the sequence
$seq = $this->getSequence($sequence);
if ($seq->recordCount() != 1) return -1;
- $minvalue = $seq->f['min_value'];
+ $minvalue = $seq->fields['min_value'];
/* This double-cleaning is deliberate */
$this->fieldClean($sequence);
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres74.php,v 1.55 2006/09/24 23:42:41 xzilla Exp $
+ * $Id: Postgres74.php,v 1.56 2007/01/10 02:01:17 soranzo Exp $
*/
include_once('./classes/database/Postgres73.php');
}
// Otherwise find the names of the keys
else {
- $attnames = $this->getAttributeNames($oldtable, explode(' ', $rs->f['indkey']));
+ $attnames = $this->getAttributeNames($oldtable, explode(' ', $rs->fields['indkey']));
if (!is_array($attnames)) {
$this->rollbackTransaction();
return -1;
$this->clean($cycledvalue);
$sql = "ALTER SEQUENCE \"{$sequence}\"";
- if ($increment != '' && $increment != $data->f['increment_by']) $sql .= " INCREMENT {$increment}";
- if ($minvalue != '' && $minvalue != $data->f['min_value']) $sql .= " MINVALUE {$minvalue}";
- if ($maxvalue != '' && $maxvalue != $data->f['max_value']) $sql .= " MAXVALUE {$maxvalue}";
- if ($startvalue != '' && $startvalue != $data->f['last_value']) $sql .= " START {$startvalue}";
- if ($cachevalue != '' && $cachevalue != $data->f['cache_value']) $sql .= " CACHE {$cachevalue}";
+ if ($increment != '' && $increment != $data->fields['increment_by']) $sql .= " INCREMENT {$increment}";
+ if ($minvalue != '' && $minvalue != $data->fields['min_value']) $sql .= " MINVALUE {$minvalue}";
+ if ($maxvalue != '' && $maxvalue != $data->fields['max_value']) $sql .= " MAXVALUE {$maxvalue}";
+ if ($startvalue != '' && $startvalue != $data->fields['last_value']) $sql .= " START {$startvalue}";
+ if ($cachevalue != '' && $cachevalue != $data->fields['cache_value']) $sql .= " CACHE {$cachevalue}";
// toggle cycle yes/no
$sql .= (!$cycledvalue ? ' NO ' : '') . " CYCLE";