On Tue, 20 Jan 2009, Stephen R. van den Berg wrote:


[...]
      val = map(val, lambda(mixed x) {
-                      if (x) return x;
-                      // Might be a dbnull object which considers
-                      // itself false (e.g. in the oracle glue).
-                      if ((x != 0) && stringp(x->type))
-                        // Transform NULLString to "".
-                        return x->type;
-                      // It's 0 or a null object. Treat it as the value
+                      // If it's a null object. Treat it as the value
                       // doesn't exist at all (ideally there should be
                       // some sort of dbnull value at the rxml level
                       // too to tell these cases apart).
-                      return RXML.nil;
+                      return x ? x : RXML.nil;
                     });

This patch is unsafe, since it changes the handling of "" for results from Oracle (Oracle doesn't differentiate between "" and NULL for string fields).



--
Henrik Grubbström                                       [email protected]
Roxen Internet Software AB

Reply via email to