Hey

I've updated the suggested changes: 
https://github.com/jeremyevans/sequel/compare/master...jrgns:odbc-bit-is-boolean

This doesn't have an effect on the date / time conversions, and I've 
enabled the tests for boolean types.

I tried looking at the use_time option that ODBC provides, but the effect 
it has is a bit above my paygrade and time constraints. I'll try again when 
I have more time.

Thoughts?

Jrgns

On Friday, 10 April 2015 10:34:13 UTC+2, Jurgens du Toit wrote:
>
> Kewl. I ran the test with and without the option, and there were some 
> failures, but I think it's worth fixing. I'll look into it in more detail 
> later.
>
> Thanx!
> J
>
> On Friday, 10 April 2015 10:26:37 UTC+2, Jeremy Evans wrote:
>>
>> On Thursday, April 9, 2015 at 9:58:14 PM UTC-7, Jurgens du Toit wrote:
>>>
>>> Hey
>>>
>>> I started running the tests, and while further researching I came across 
>>> this ODBC option (from http://www.ch-werner.de/rubyodbc/odbc.html):
>>>
>>> use_time[=bool]Sets or queries the mapping of SQL_DATE, SQL_TIME, and 
>>> SQL_TIMESTAMP data types to Ruby objects. When true, SQL_DATE is mapped to 
>>> Ruby Date objects, SQL_TIME and SQL_TIMESTAMP are mapped to Ruby Time 
>>> objects. Otherwise (default) ODBC::Date 
>>> <http://www.ch-werner.de/rubyodbc/odbc.html#ODBC::Date>, ODBC::Time 
>>> <http://www.ch-werner.de/rubyodbc/odbc.html#ODBC::Time>, and 
>>> ODBC::TimeStamp <http://www.ch-werner.de/rubyodbc/odbc.html#ODBC::Time> 
>>> are used.
>>> Is there a reason why this wasn't used? I tried using that and then not 
>>> doing the time/date related conversions, but there seems to be other 
>>> (timezone) related issues, even if you also use the use_utc option. Was it 
>>> considered before and discarded for some reason?
>>>
>>
>> I don't think it was considered before.  In general the odbc adapter gets 
>> little attention because there are usually better options.  It hasn't 
>> changed much in the 7 years I've been maintaining Sequel.  However, if that 
>> is the only option that supports Windows Integrated Authentication, then it 
>> makes sense to use it.
>>
>> You could try running the tests both with and without the use_time option 
>> set, and see if there are any tests that change from pass to fail.  If 
>> things are not worse with use_time = true set, I think that change would 
>> make sense as it should simplify the code.
>>
>> I'm OK with the handling the SQL bit type as boolean, I just want to make 
>> sure it doesn't break anything else that is currently working.
>>
>> Thanks,
>> Jeremy
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.

Reply via email to