diff --git a/include/class.dynamic_forms.php b/include/class.dynamic_forms.php
index 279f58a3d9cdd36f41e64731e6ce70badadf54bb..e4b030db4057d1cdbaa14a9478f449e4441bea2c 100644
--- a/include/class.dynamic_forms.php
+++ b/include/class.dynamic_forms.php
@@ -946,7 +946,8 @@ class DynamicFormEntryAnswer extends VerySimpleModel {
     }
 
     function getSearchKeys() {
-        $val = $this->getValue();
+        $val = $this->getField()->to_php(
+            $this->get('value'), $this->get('value_id'));
         if (is_array($val))
             return array_keys($val);
         elseif (is_object($val) && method_exists($val, 'getId'))