Vergleich inc/db_pgsql.php - 1.8.0 - 1.8.5

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 8Zeile 8
 *
*/


 *
*/


class DB_PgSQL

class DB_PgSQL implements DB_Base

{
/**
* The title of this layer.

{
/**
* The title of this layer.

Zeile 601Zeile 601
	}

/**

	}

/**

	 * Lists all functions in the database.

	 * Lists all tables in the database.

	 *
* @param string The database name.
* @param string Prefix of the table (optional)

	 *
* @param string The database name.
* @param string Prefix of the table (optional)

Zeile 760Zeile 760
			}
else
{

			}
else
{

				$array[$field] = "'{$value}'";

				$array[$field] = $this->quote_val($value);

			}
}


			}
}


Zeile 812Zeile 812
				}
else
{

				}
else
{

					$values[$field] = "'{$value}'";

					$values[$field] = $this->quote_val($value);

				}
}
$insert_rows[] = "(".implode(",", $values).")";

				}
}
$insert_rows[] = "(".implode(",", $values).")";

Zeile 862Zeile 862
			}
else
{

			}
else
{

				$query .= $comma.$field."={$quote}{$value}{$quote}";



				$quoted_value = $this->quote_val($value, $quote);

$query .= $comma.$field."={$quoted_value}";

			}
$comma = ', ';

			}
$comma = ', ';

		}

		}

		if(!empty($where))

		if(!empty($where))

		{

		{

			$query .= " WHERE $where";

			$query .= " WHERE $where";

		}

		}

		return $this->write_query("
UPDATE {$this->table_prefix}$table
SET $query
");

		return $this->write_query("
UPDATE {$this->table_prefix}$table
SET $query
");

 
	}

private function quote_val($value, $quote="'")
{
if(is_int($value))
{
$quoted = $value;
}
else
{
$quoted = $quote . $value . $quote;
}

return $quoted;

	}

/**

	}

/**

Zeile 1299Zeile 1315
				}
else
{

				}
else
{

					$search_bit[] = "{$field} = '".$replacements[$field]."'";

					$search_bit[] = "{$field} = ".$this->quote_val($replacements[$field]);

				}
}


				}
}


Zeile 1332Zeile 1348
			}
else
{

			}
else
{

				return $this->update_query($table, $replacements, "{$main_field}='".$replacements[$main_field]."'");

				return $this->update_query($table, $replacements, "{$main_field}=".$this->quote_val($replacements[$main_field]));

			}
}
else

			}
}
else