[ZBX-5737] Can not import images with Oracle backend Created: 2012 Oct 25 Updated: 2017 May 30 Resolved: 2012 Dec 10 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Frontend (F) |
Affects Version/s: | 2.0.4rc1, 2.1.0 |
Fix Version/s: | 2.0.5rc1, 2.1.0 |
Type: | Incident report | Priority: | Major |
Reporter: | Alexey Pustovalov | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Labels: | images, oracle | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Issue Links: |
|
Description |
We do not use $image['image'] for Oracle database! |
Comments |
Comment by Alexey Pustovalov [ 2012 Oct 25 ] |
Small patch: Index: frontends/php/api/classes/CImage.php =================================================================== --- frontends/php/api/classes/CImage.php (revision 30950) +++ frontends/php/api/classes/CImage.php (working copy) @@ -338,6 +338,13 @@ - if (!oci_execute($stmt)) { + if (!oci_execute($stmt, OCI_DEFAULT)) { $e = oci_error($stid); self::exception(ZBX_API_ERROR_PARAMETERS, _s('Execute SQL error [%1$s] in [%2$s].', $e['message'], $e['sqltext'])); } + + if (!$lob->save($image['image'])) { + $e = oci_error($stid); + self::exception(ZBX_API_ERROR_PARAMETERS, _s('Image load error [%1$s] in [%2$s].', $e['message'], $e['sqltext'])); + } + $lob->free(); + oci_free_statement($stmt); break; case ZBX_DB_DB2: |
Comment by Eduards Samersovs (Inactive) [ 2012 Oct 26 ] |
Fixed in development branch svn://svn.zabbix.com/branches/dev/ZBX-5737 |
Comment by Toms (Inactive) [ 2012 Nov 16 ] |
TESTED |
Comment by Eduards Samersovs (Inactive) [ 2012 Nov 19 ] |
Fixed in versions pre-2.1.0 (beta) r31497, pre-2.0.4rc1 r31495 |
Comment by Pavels Jelisejevs (Inactive) [ 2012 Nov 20 ] |
(1) Please note this in the API changelog. Eduards RESOLVED jelisejev Thank you, CLOSED. |
Comment by richlv [ 2012 Nov 21 ] |
(2) must be reverted for 2.0 branch - string freeze. Eduards REVERTED 31608! <richlv> trunk changelog entry removed in r31610, CLOSED |
Comment by Eduards Samersovs (Inactive) [ 2012 Dec 10 ] |
Fixed in versions pre-2.0.5rc1 r32029 |