[Ruby-informix-misc] INTERVAL datatype support
Gerardo Santana Gómez Garrido
gerardo.santana at gmail.com
Mon Mar 24 22:44:32 EDT 2008
I've just committed the code for supporting the INTERVAL datata type.
For your information, here's the commit message:
* Informix::Interval class for binding input and output INTERVAL parameters
* year_to_month, day_to_fraction, from_months and from_seconds class methods
for creating Interval objects
* Basic operations (+, -, *, /) available with Integer, Rational, Date, Time and
* #to_a method for returning each field of an Interval object (years, months,
days, hours, minutes, seconds, fraction)
* #to_s method for displaying an Interval object as an string according to
ANSI SQL standards
* Includes the Comparable module, for comparing with other Interval objects
It already works right now.
Please feel free to try it and criticize it.
I can provide you a rubygem if anyone wants to try it. I would
appreciate any comments.
More information about the Ruby-informix-misc