[Nitro] sql.rb read_prop for TrueClass

Tim Larson tim at keow.org
Tue Sep 20 13:32:15 EDT 2005


On Tue, Sep 20, 2005 at 06:26:41PM +0100, Tim Larson wrote:
> This:
>     elsif p.klass.ancestors.include?(TrueClass)
>           return "('0' != res[#{col} + offset])"
> 
> Should change to this:
>     elsif p.klass.ancestors.include?(TrueClass)
>           return "('t' == res[#{col} + offset])"

...and mysql.rb needs a similar change, from:
    elsif p.klass.ancestors.include?(TrueClass)
      return "('0' != res[#{col} + offset])"

To:
    elsif p.klass.ancestors.include?(TrueClass)
      return "('1' == res[#{col} + offset])"

...to match how write_prop for mysql stores either
a '1' or a NULL.

--Tim Larson



More information about the Nitro-general mailing list