View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0013210 | mantisbt | db postgresql | public | 2011-08-05 22:04 | 2016-07-11 15:41 |
Reporter | Chris Kobrzak | Assigned To | |||
Priority | low | Severity | tweak | Reproducibility | N/A |
Status | new | Resolution | open | ||
Product Version | 1.2.6 | ||||
Summary | 0013210: Adding support for PostgreSQL schemas | ||||
Description | I've just installed MantisBT on my local computer choosing Postgres as the back-end. I've run into an issue with one of the installer's ALTER TABLE queries running against mantis_user_pref_table that was trying to change the redirect_delay boolean column to INTEGER but I managed to work around it (I'm going to log it a separate ticket at some point). However, the issue with the installer is it doesn't seem to support PostgreSQL schemas (http://www.postgresql.org/docs/9.0/static/ddl-schemas.html ). 1) change the name of your schema to, say, myschema; this can be done with the following query: 2) add the following line to config_inc.php: 3) locate the db_connect method in core/database_api.php 4) find a piece of logic where the db_is_mysql() method is called (in my case this is line 102) 5) add the following else-if statement between MySQL and DB2 checks: else if (db_is_pgsql() && $p_db_schema !== null && !is_blank( $p_db_schema ) ) { That's it. Your MantisBT instance is now setting the DB schema to whatever's been set in the config file. I hope this helps. | ||||
Additional Information | Tested with PostgreSQL 9.0 and PHP 5.3.4 on OS X. | ||||
Tags | No tags attached. | ||||
MantisBT currently supports Mysql and has support for other database engines. The support for other databases is known to be problematic. Having implemented the current database layer into Mantis 10 years ago, I'm currently working on replacing the current layer. If you are interested in using Mantis with non-mysql databases - for example, Oracle, PGSQL or MSSQL, and would be willing to help out testing the new database layer, please drop me an email at paul@mantisforge.org In the meantime, I'd advise running Mantis with Mysql Only to avoid issues. Thanks |
|
Reminder sent to: dregad, grangeway Not sure, maybe this issue should be moved back to project mantis . |
|