View Issue Details

IDProjectCategoryView StatusLast Update
0022005mantisbtsqlpublic2017-02-01 22:47
Reportercproensa Assigned Tocproensa  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Version1.3.0 
Target Version1.3.6Fixed in Version1.3.6 
Summary0022005: Database log for postgres/oracle not showing parameter substitution
Description

When showing queries in database log, or by showing them in page, the parameters are not replaced by their binded values.
This functionality only happens with mysql.

Example, this query in mysql is printed in log as:
SELECT * from mantis_user_table WHERE id=1 and access_level=90

while, postgres:
SELECT * from mantis_user_table WHERE id=$1 and access_level=$2

oracle:
SELECT * from mantis_user_table WHERE id=:0 and access_level=:1

TagsNo tags attached.

Relationships

related to 0022018 closedcproensa Database log does not show boolean parameters correctly 

Activities

Related Changesets

MantisBT: master-1.3.x 0a88ed48

2016-12-03 15:07

cproensa

Committer: dregad


Details Diff
Improve parameter substitution for database log

For showing the database query log, only mysql style parameters "?" were
supported. Other like postgres "$nnn" or oracle ":xxx" were not treated.

Change the token substitution to allow other token types to be replaced
with the parameter value for log output.

Fixes: 0022005
Affected Issues
0022005
mod - core/database_api.php Diff File