https://bugzilla.wikimedia.org/show_bug.cgi?id=26612
Tim Starling <tstarl...@wikimedia.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tstarl...@wikimedia.org --- Comment #6 from Tim Starling <tstarl...@wikimedia.org> 2011-01-27 02:33:19 UTC --- One problem is that DatabaseBase::selectDB() does not work for SQLite or PostgreSQL, so it should not be used in DBMS-independent code. In particular, needsUpgrade() is broken because it depends on selectDB() returning false if the database does not exist. I think PostgresqlInstaller should check for the existence of the database by attempting to connect to it with the administrative credentials, and checking the resulting error message for "FATAL: database "..." does not exist". There's no guarantee that the administrative user will be able to connect to the template1 database, or any other specific database, so you can't use the pg_database catalog. If the database doesn't exist, I think it's fair to assume that you need to be able to connect to the "postgres" administrative database in order to create one. The old installer relied on creation of a special user to ensure that the session settings were correct: $SQL = "ALTER USER $safeuser SET timezone = 'GMT'"; $SQL = "ALTER USER $safeuser SET datestyle = 'ISO, YMD'"; This is missing from the new installer, which is good, but DatabasePostgres::open() should make sure the correct settings are set in the session. Dropping support for full text search before PostgreSQL 8.3 (released 2008) would allow the setup code to be substantially simpler. The "schema for tsearch2" ($wgDBts2schema) setting could be dropped, currently it does nothing in PostgreSQL 8.3 or later. SearchPostgres.php would be slightly simpler. -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list Wikibugs-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikibugs-l