Mantis Bugtracker          
testlink.org

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0008525TestLinkDatabase Postgrespublic2018-12-27 13:532018-12-29 09:05
Reportererny 
Assigned To 
PrioritynormalSeverityfeature requestReproducibilityalways
StatusnewResolutionopen 
PlatformMac OS XOSOS XOS Version10.9.5
Product Version1.9.18 (2018 Q3) 
Fixed in Version 
Summary0008525: Postgres support through PDO driver
DescriptionI'm not able to install PHP with native postgres support, although I do have Postgres PDO (pdo_pgsql) support enabled.
Additional InformationI'm willing to work on this.
TagsNo tags attached.
Database (MySQL,Postgres,etc)Postgres
Browser
PHP Version5.6
TestCaseID
QA Team - Task Workflow Status
Attached Files

- Relationships

-  Notes
(0028391)
fman (administrator)
2018-12-27 16:25
edited on: 2018-12-27 16:27

this is your choice, but I'm not going to provide support on this, till will not be the only available choice.
Hope you will understand

if
>> I'm willing to work on this.
means you will provide changes with config option to enable/disable this through a Pull request, I'm going to give a look

have you checked if there is a change with ADODB PHP to use PDO drivers ?

(0028392)
erny (reporter)
2018-12-28 11:31
edited on: 2018-12-28 11:41

I'm using ADO PDO Driver, but teslink_1_9 branch seems not to support it out of the box.

Here goes first version of PR: https://github.com/TestLinkOpenSourceTRMS/testlink-code/pull/182 [^]

The current changes are only considering the postgres case, checking for drivers pgsql and pdo_pgsql. This should be backwards compatible (note that I'm writing a new value to config_db.inc.php).

IMHO: database and driver used to access it should be separated into two values: the database tells the SQL dialect and the driver is a low level issue (if PHP has support for it or not). Although, installNewDB lists it separately (pgsql Fail, pdo_pgsql OK), perhaps the end user should only be informed which DB as accessible and which driver it uses (or in case it failed, which drivers has been tested for). I just didn't want to change the code too much.

Other backends to consider could be: pdo_mssql, pdo_mysql, pdo_oci (oracle), pdo_sqlite, pdo_sqlsrv.

Regards.

(0028393)
fman (administrator)
2018-12-28 13:13

A short but clear description of changes done from a logical point of view is needed, because the code IMHO cannot be the source of the design choice

>> IMHO: database and driver used to access it should be separated into two values
need to think about, but do not think this is a good thing to do.

It will be interesting to understand why using PDO is a must or not.
Also, it will be interesting to understand why you can not install the other kind of drivers.

Checking ADOBPHP documentation, I've found (if I'm not wrong) that for postgres the suggested driver is postgres9 and not anything related to PDO.

In addition due to how this application is managed, talking about other PDO drivers in this issue is wrong.

Just for the records, I'm using postgres on MacOS using MAMP without any issues.
(0028395)
erny (reporter)
2018-12-28 20:27

Ok, leave it on stand-by.

I'm using php installed through homebrew. I was not able to configure it with native postgres support. But I had pdo_postgres support enabled. For me, it's working ok now.
(0028399)
fman (administrator)
2018-12-29 09:05

according to ADODB site

http://adodb.org/dokuwiki/doku.php?id=v5:database:pdo [^]

- Issue History
Date Modified Username Field Change
2018-12-27 13:53 erny New Issue
2018-12-27 16:25 fman Note Added: 0028391
2018-12-27 16:27 fman Note Edited: 0028391 View Revisions
2018-12-27 16:27 fman Status new => feedback
2018-12-28 11:31 erny Note Added: 0028392
2018-12-28 11:31 erny Status feedback => new
2018-12-28 11:41 erny Note Edited: 0028392 View Revisions
2018-12-28 13:13 fman Note Added: 0028393
2018-12-28 20:27 erny Note Added: 0028395
2018-12-29 09:05 fman Note Added: 0028399



Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker