Index: /trunk/htdocs2/GreenZone/Utils/OCIDB.php
===================================================================
--- /trunk/htdocs2/GreenZone/Utils/OCIDB.php	(revision 447)
+++ /trunk/htdocs2/GreenZone/Utils/OCIDB.php	(revision 448)
@@ -36,5 +36,5 @@
   /// failed.
 
-  private function priv_Connect( $target_user, $target_password, $target_dsn )
+  private function prot_Connect( $target_user, $target_password, $target_dsn )
   {
     $conn = oci_connect( $target_user, $target_password, $target_dsn );
@@ -42,10 +42,10 @@
       $this->link = $conn;
     else
-      throw new OCIDBException( 'Failed to connect to OCI database', 'OCIDB::connect' );
+      throw new OCIDBException( 'Failed to connect to OCI database', 'OCIDB::prot_Connect' );
   }
   
   /// Disconnect from the database.
   
-  private function priv_Disconnect()
+  private function prot_Disconnect()
   {
     oci_close( $this->link );
@@ -55,8 +55,8 @@
   /// Perform the query given and store the results in $this->last_dataset.
 
-  private function priv_DoQuery( $sql )
+  private function prot_DoQuery( $sql )
   {
     if( $this->connection == null )
-      throw new OCIDBException( 'Attempt to perform query without connection', 'OCIDB::DoQuery' );
+      throw new OCIDBException( 'Attempt to perform query without connection', 'OCIDB::prot_DoQuery' );
     
     $query = oci_parse( $this->link, sql );
@@ -77,7 +77,7 @@
   /// into an oci database in this project.
 
-  private function priv_GetInsertID()
+  private function prot_GetInsertID()
   {
-    throw new OCIDBException( 'Not implemented', 'OCIDB::priv_GetInsertID' );
+    throw new OCIDBException( 'Not implemented', 'OCIDB::prot_GetInsertID' );
   }
 };
Index: /trunk/htdocs2/GreenZone/Utils/SQLDatabase.php
===================================================================
--- /trunk/htdocs2/GreenZone/Utils/SQLDatabase.php	(revision 447)
+++ /trunk/htdocs2/GreenZone/Utils/SQLDatabase.php	(revision 448)
@@ -31,21 +31,21 @@
   }
   
-  public function __destruct() { $this->priv_Disconnect(); }
+  public function __destruct() { $this->prot_Disconnect(); }
   
   // MAIN INTERFACE - override the private versions of these functions.
   
-  public function Connect( $db_user, $db_password, $db_dsn ) { $this->priv_Connect( $db_user, $db_password, $db_dsn ); }
-  public function EnsureConnected() { $this->priv_EnsureConnected(); }
-  public function EnsureNumRows( $comparison, $num ) { $this->priv_EnsureNumRows( $comparison, $num ); }
-  public function FetchNumRows() { return $this->priv_FetchNumRows(); }
-  public function FetchRowAsArray() { return $this->priv_FetchRowAsArray(); }
-  public function DoQuery( $sql ) { $this->priv_DoQuery( $sql ); }
+  public function Connect( $db_user, $db_password, $db_dsn ) { $this->prot_Connect( $db_user, $db_password, $db_dsn ); }
+  public function EnsureConnected() { $this->prot_EnsureConnected(); }
+  public function EnsureNumRows( $comparison, $num ) { $this->prot_EnsureNumRows( $comparison, $num ); }
+  public function FetchNumRows() { return $this->prot_FetchNumRows(); }
+  public function FetchRowAsArray() { return $this->prot_FetchRowAsArray(); }
+  public function DoQuery( $sql ) { $this->prot_DoQuery( $sql ); }
   public function GetLastResult() { return $this->last_dataset; }
   public function GetInsertID() { return $this->GetInsertID(); }
-  public function SelectByFields( $table_name, $field_specs ) { $this->priv_SelectByFields( $table_name, $field_specs ); }
+  public function SelectByFields( $table_name, $field_specs ) { $this->prot_SelectByFields( $table_name, $field_specs ); }
   public function SetFieldsByFields( $table_name, $set_fields, $match_fields )
-    { $this->priv_SetFieldsByFields( $table_name, $set_fields, $match_fields ); }
-  public function InsertWithFields( $table_name, $field_specs ) { $this->priv_InsertWithFields( $table_name, $field_specs ); }
-  public function InsertTupleUsingAssoc( $table_name, $tuple ) { $this->priv_InsertTupleUsingAssoc( $table_name, $tuple ); }
+    { $this->prot_SetFieldsByFields( $table_name, $set_fields, $match_fields ); }
+  public function InsertWithFields( $table_name, $field_specs ) { $this->prot_InsertWithFields( $table_name, $field_specs ); }
+  public function InsertTupleUsingAssoc( $table_name, $tuple ) { $this->prot_InsertTupleUsingAssoc( $table_name, $tuple ); }
 
   public function Debug() { $this->debug = 1; }
@@ -54,10 +54,10 @@
   // PRIVATE
       
-  private $link;
-  private $last_result;
-  private $last_query;
-  private $debug;
-  private $last_dataset;
-  private $last_dataset_index;
+  protected $link;
+  protected $last_result;
+  protected $last_query;
+  protected $debug;
+  protected $last_dataset;
+  protected $last_dataset_index;
   
   
@@ -66,12 +66,12 @@
   /// database class we are using.
   
-  private function priv_Connect( $db_user, $db_password, $db_dsn )
-  {
-    throw new SQLDBException( 'Bad Call, derived class should always override this function', 'SQLDatabase::priv_Connect' );
+  protected function prot_Connect( $db_user, $db_password, $db_dsn )
+  {
+    throw new SQLDBException( 'Bad Call, derived class should always override this function', 'SQLDatabase::prot_Connect' );
   }
   
   /// Simply throw an exception if we are not connected to the database.
 
-  private function priv_EnsureConnected()
+  protected function prot_EnsureConnected()
   {
     if( !$this->link )
@@ -83,5 +83,5 @@
   /// Checks that the correct number of rows have been returned.
 
-  private function priv_EnsureNumRows( $comparison, $num )
+  protected function prot_EnsureNumRows( $comparison, $num )
   {
     $this->EnsureConnected();
@@ -103,5 +103,5 @@
   /// Fetch the number of rows returned by the last query
   
-  private function priv_FetchNumRows()
+  protected function prot_FetchNumRows()
   {
     if( $this->last_dataset == null )
@@ -114,5 +114,5 @@
   /// Fetch the next row as an array
   
-  private function priv_FetchRowAsArray()
+  protected function prot_FetchRowAsArray()
   {
     if( $this->last_dataset_index >= $this->FetchNumRows() )
@@ -126,5 +126,5 @@
   /// TODO write a neutral version of this.
   
-  private function priv_GetInsertID()
+  protected function prot_GetInsertID()
   {
 //     $this->EnsureConnected();
@@ -141,5 +141,5 @@
   /// of field => value parameters.
   
-  private function priv_SelectByFields( $table_name, $field_specs )
+  protected function prot_SelectByFields( $table_name, $field_specs )
   {
     $select_sql = ' SELECT * FROM ' . $table_name . ' WHERE ';
@@ -174,5 +174,5 @@
   /// and the fields to change.
 
-  private function priv_SetFieldsByFields( $table_name, $set_fields, $match_fields )
+  protected function prot_SetFieldsByFields( $table_name, $set_fields, $match_fields )
   {
     if( count( $set_fields ) < 2 || count( $match_fields ) < 2 )
@@ -224,5 +224,5 @@
   /// is better.
   
-  private function priv_InsertWithFields( $table_name, $field_specs )
+  protected function prot_InsertWithFields( $table_name, $field_specs )
   {
     $insert_sql = ' INSERT INTO ' . $table_name . ' ( ';
@@ -255,5 +255,5 @@
   /// Build and execute an insert query using the associative array of field=>values
   
-  private function priv_InsertTupleUsingAssoc( $table_name, $tuple )
+  protected function prot_InsertTupleUsingAssoc( $table_name, $tuple )
   {
     $insert_sql = ' INSERT INTO ' . $table_name . ' ( ';
