2011-03-01 Miguel de Dios <miguel.dedios@artica.es>
* install.php: modified the source code for install postgreSQL DB to make the pandora user db as owner of tables. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4043 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
9d8ed7e20f
commit
c568805090
|
@ -1,3 +1,8 @@
|
|||
2011-03-01 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* install.php: modified the source code for install postgreSQL DB to make
|
||||
the pandora user db as owner of tables.
|
||||
|
||||
2011-03-01 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* include/db/postgresql.php, include/db/mysql.php, include/functions_db.php:
|
||||
|
|
|
@ -670,7 +670,7 @@ function install_step4() {
|
|||
|
||||
if (pg_result_status($result) != PGSQL_FATAL_ERROR) {
|
||||
//Set the privileges for DB
|
||||
pg_send_query($connection, "GRANT ALL PRIVILEGES ON DATABASE pandora to pandora;");
|
||||
pg_send_query($connection, "GRANT ALL PRIVILEGES ON DATABASE pandora TO pandora;");
|
||||
$result = pg_get_result($connection);
|
||||
|
||||
$setDBPrivileges = 0;
|
||||
|
@ -690,7 +690,16 @@ function install_step4() {
|
|||
|
||||
$correct = 1;
|
||||
foreach ($tables as $table) {
|
||||
pg_send_query($connection, "GRANT ALL PRIVILEGES ON TABLE " . $table . " to pandora;");
|
||||
pg_send_query($connection, "GRANT ALL PRIVILEGES ON TABLE " . $table . " TO pandora;");
|
||||
$result = pg_get_result($connection);
|
||||
|
||||
if (pg_result_status($result) == PGSQL_FATAL_ERROR) {
|
||||
$correct = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
//For each table make owner pandora
|
||||
pg_send_query($connection, "ALTER TABLE " . $table . " OWNER TO pandora;");
|
||||
$result = pg_get_result($connection);
|
||||
|
||||
if (pg_result_status($result) == PGSQL_FATAL_ERROR) {
|
||||
|
|
Loading…
Reference in New Issue