From 5bce69de6fda2eb2516c47f07cd5e2d90b07a60d Mon Sep 17 00:00:00 2001 From: MarkBaker Date: Wed, 12 Nov 2014 22:21:47 +0000 Subject: [PATCH] Bugfix: (frozenstupidity) Work Item GH-423 - Fix invalid NA return in VLOOKUP Manual merge --- Classes/PHPExcel/Calculation/LookupRef.php | 9 ++------- changelog.txt | 3 ++- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/Classes/PHPExcel/Calculation/LookupRef.php b/Classes/PHPExcel/Calculation/LookupRef.php index 94f42e5..75e7f69 100644 --- a/Classes/PHPExcel/Calculation/LookupRef.php +++ b/Classes/PHPExcel/Calculation/LookupRef.php @@ -735,11 +735,7 @@ class PHPExcel_Calculation_LookupRef { return PHPExcel_Calculation_Functions::NA(); } else { // otherwise return the appropriate value - $result = $lookup_array[$rowNumber][$returnColumn]; - if ((is_numeric($lookup_value) && is_numeric($result)) || - (!is_numeric($lookup_value) && !is_numeric($result))) { - return $result; - } + return $lookup_array[$rowNumber][$returnColumn]; } } @@ -802,8 +798,7 @@ class PHPExcel_Calculation_LookupRef { return PHPExcel_Calculation_Functions::NA(); } else { // otherwise return the appropriate value - $result = $lookup_array[$returnColumn][$rowNumber]; - return $result; + return $lookup_array[$returnColumn][$rowNumber]; } } diff --git a/changelog.txt b/changelog.txt index d4e5947..0ae0d63 100644 --- a/changelog.txt +++ b/changelog.txt @@ -34,7 +34,8 @@ Planned for v1.8.1 - Bugfix: (MBaker) - Fix for percentage operator in formulae for BIFF Writer - Bugfix: (MBaker) - Fix to getStyle() call for cell object - Bugfix: (MBaker) - Discard Autofilters in Excel2007 Reader when filter range isn't a valid range -- Bugfix: (masanaikeshima) Work Item GH-426 - Pie chart won't work in Excel 2013 +- Bugfix: (MBaker) - Discard Autofilters in Excel2007 Reader when filter range isn't a valid range +- Bugfix: (frozenstupidity) Work Item GH-423 - Fix invalid NA return in VLOOKUP - General: (MBaker) - Small performance improvement for autosize columns - General: (frost-nzcr4) Work Item GH-379 - Change the getter/setter for zeroHeight to camel case - General: (MBaker) Work Item GH-394 - DefaultValueBinder is too much aggressive when converting string to numeric