Rev 1204 | Rev 1316 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1204 | Rev 1236 | ||
---|---|---|---|
Line 97... | Line 97... | ||
97 | foreach ($ret as &$value) { |
97 | foreach ($ret as &$value) { |
98 | if ($value === chr(0)) $value = 0; |
98 | if ($value === chr(0)) $value = 0; |
99 | if ($value === chr(1)) $value = 1; |
99 | if ($value === chr(1)) $value = 1; |
100 | } |
100 | } |
101 | 101 | ||
102 | // Oracle returns $ret['VALUE'] because unquoted column-names are always upper-case |
102 | // Oracle and Firebird returns $ret['VALUE'] because unquoted column-names are always upper-case |
103 | // We can't quote every single column throughout the whole program, so we use this workaround... |
103 | // We can't quote every single column throughout the whole program, so we use this workaround... |
104 | if (is_array($ret)) { |
104 | if (is_array($ret)) { |
105 | $keys = array_keys($ret); |
- | |
106 | foreach ($keys as $key) { |
105 | foreach ($ret as $name => $val) { |
107 | $ret[strtolower($key)] = $ret[$key]; |
106 | $ret[strtolower($name)] = $val; |
108 | $ret[strtoupper($key)] = $ret[$key]; |
107 | $ret[strtoupper($name)] = $val; |
109 | } |
108 | } |
110 | } else if (is_object($ret)) { |
109 | } else if (is_object($ret)) { |
111 | foreach ($ret as $name => $val) { |
110 | foreach ($ret as $name => $val) { |
112 | $ret->{strtoupper($name)} = $val; |
111 | $ret->{strtoupper($name)} = $val; |
113 | $ret->{strtolower($name)} = $val; |
112 | $ret->{strtolower($name)} = $val; |
114 | } |
113 | } |
- | 114 | } else { |
|
- | 115 | assert(false); |
|
115 | } |
116 | } |
116 | } |
117 | } |
117 | 118 | ||
118 | /** |
119 | /** |
119 | * Please override do_fetch_object(), do_fetch_array(), or both. |
120 | * Please override do_fetch_object(), do_fetch_array(), or both. |