Index: trunk/phase3/includes/DatabasePostgres.php |
— | — | @@ -486,6 +486,15 @@ |
487 | 487 | $this->doQuery("SET client_min_messages = 'ERROR'"); |
488 | 488 | } |
489 | 489 | |
| 490 | + global $wgDBmwschema, $wgDBts2schema; |
| 491 | + if (isset( $wgDBmwschema ) && isset( $wgDBts2schema ) |
| 492 | + && $wgDBmwschema !== 'mediawiki' |
| 493 | + && preg_match( '/^\w+$/', $wgDBmwschema ) |
| 494 | + && preg_match( '/^\w+$/', $wgDBts2schema ) |
| 495 | + ) { |
| 496 | + $this->doQuery("SET search_path = $wgDBmwschema, $wgDBts2schema, public"); |
| 497 | + } |
| 498 | + |
490 | 499 | return $this->mConn; |
491 | 500 | } |
492 | 501 | |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -24,8 +24,9 @@ |
25 | 25 | * Add a warning for non-descriptive filenames at Special:Upload |
26 | 26 | * Add {{filepath:}} parser function to get full path to an uploaded file, |
27 | 27 | complementing {{fullurl:}} for pages. |
| 28 | +* (bug 11136) If using Postgres, search path is explicitly set if wgDBmwschema is |
| 29 | + not set to 'mediawiki', allowing multiple mediawiki instances per user. |
28 | 30 | |
29 | | - |
30 | 31 | === Bug fixes in 1.12 === |
31 | 32 | |
32 | 33 | * Subpages are now indexed for searching properly when using PostgreSQL |