These are chat archives for rails-sqlserver/activerecord-sqlserver-adapter

29th
Jan 2015
Ken Collins
@metaskills
Jan 29 2015 00:31
FYI, just finished up FK support.
rails-sqlserver/activerecord-sqlserver-adapter@51aab54
That makes sense.
Sean Griffin
@sgrif
Jan 29 2015 01:28
Nice
Looks slick
I decided to break out define_attribute, which is what both attribute and schema detection use internally (which will also be public)
def attribute(name, type_or_magic_symbol, **options)
  after_schema_loaded do
    define_attribute(name, lookup_type_for_magic_symbol_because_david_says_i_have_to(type_or_magic_symbol), options)
  end
end
Ken Collins
@metaskills
Jan 29 2015 13:12
Morning.
I released v4.2.0 last night. Get it while it’s hot. Next week I will be working on closing all existing issues and PRs for the v4.2.1 release.
Sean Griffin
@sgrif
Jan 29 2015 16:48
:+1:
Ken Collins
@metaskills
Jan 29 2015 19:54
Sean, you on the core list? LIke yea, you should be.
I just sent a reply to Prem.
Again, thanks for all your help here.
Sean Griffin
@sgrif
Jan 29 2015 19:55
I just saw the thread
Thanks for the reply, I'm glad I've been able to help!
Michael Lang
@mwlang
Jan 29 2015 20:40
Hey, just saw your reply on issue #359
Ken Collins
@metaskills
Jan 29 2015 20:41
Hey Michael!
Michael Lang
@mwlang
Jan 29 2015 20:41
Am I interpreting correctly that this gem is retiring all support for earlier than 2012 SQL Server?
Ken Collins
@metaskills
Jan 29 2015 20:41
It depends on how you look at it.
Michael Lang
@mwlang
Jan 29 2015 20:42
:-o
Ken Collins
@metaskills
Jan 29 2015 20:42
And what you define as “support”.
But yes, the adapter is 2012 and upward now for 4.2 and further.
This does not mean that 4.1 is any less viable that it was a few weeks ago.
If you are on 2008 and lower, it is a very very strong framework.
And if there are any issues that are painful for people, I would be more than happy to get them fixed in any one of our appropraite branches and release new gems.
Michael Lang
@mwlang
Jan 29 2015 20:44
I'm just trying to figure out how I might many my clients...I've got three different customers and they're all on 2005 (I just got one to finally upgrade from 2000 to 2005 -- and they wouldn't even go to 2008) -- most of them site expense of licensing or concern for compatibility.
Ken Collins
@metaskills
Jan 29 2015 20:44
But I did want to be honest on my personally free time, I myself am focusing on current.
Michael Lang
@mwlang
Jan 29 2015 20:44
that's good. and there's no problem with me with that. I appreciate all you do do already.
Ken Collins
@metaskills
Jan 29 2015 20:45
Word… so yea...
Michael Lang
@mwlang
Jan 29 2015 20:45
another question: I had to port tiny_tds and backwards to Rails 1.2 and Ruby 1.8.7.
Ken Collins
@metaskills
Jan 29 2015 20:45
I suspect there will be others that can step up for themselves and/or their clients to make 4-1-stable better.
Wow.
Your life aint easy :)
Michael Lang
@mwlang
Jan 29 2015 20:46
So I encountered a lot of that row number stuff you found painful.
Ken Collins
@metaskills
Jan 29 2015 20:46
When I first write TinyTDS, I tested on 1.8
Michael Lang
@mwlang
Jan 29 2015 20:46
yeah. I'm the guy people find when they can't get it done any other way.
Ken Collins
@metaskills
Jan 29 2015 20:46
Been there.
TBH, moving from 1.8 to 1.9 used to be a big deal.
1.9 to 2.1 is far easier than 1.8 to 1.9.
Michael Lang
@mwlang
Jan 29 2015 20:47
maybe you can give me some advice. I'd really like to extract that back-ported stuff into its own gem. I built it inside a vendored Rails 1.2 so I could leverage all the existing unit testing infrastructure.
any suggestions how I can extract into separate gem and still leverage the tests that exist?
Ken Collins
@metaskills
Jan 29 2015 20:48
Well, TinyTDS is easy, you just use the version before we yanked 1.8
Using TinyTDS as a “connection mode” prior to Rails 2.1 is interesting.
My advice...
Michael Lang
@mwlang
Jan 29 2015 20:49
I think that's actually what I did...I took both the TinyTDS gem and the activerecord-sqlserver-adapter gem and mashed them both up into an "tinytds" adapter.
Ken Collins
@metaskills
Jan 29 2015 20:49
Is that you branch each x-x-stable into x-x-stable-tinytds gems.
So, you might need to go to rails 1-2-stable and make 1-2-stable-tinytds
I picked up the adapter at 2-1-stable.
So you could fork us and follow whatever branch you needed.
But you likey have to have version branches vs feature branches.
Michael Lang
@mwlang
Jan 29 2015 20:51
yeah, I would call mine version branches given that I was writing to a specific rails release.
Ken Collins
@metaskills
Jan 29 2015 20:52
Hard to imagine that it is easier and cheaper to do that work vs upgrading Ruby or Rails just a bit.
I get the DB versioning.
Michael Lang
@mwlang
Jan 29 2015 20:53
heh...15,000 lines of code, 250 or so models
and they were on Windows, not Linux and constantly crashing.
so first thing I did was upgrade them from Ruby 1.8.6 on Windows to Ruby 1.8.7 on Linux and I patched Rails and wrote the new adaptor in about two week's time to get them over to a stable hosting platform.
Ken Collins
@metaskills
Jan 29 2015 20:55
Wow, kind of been there too.
You should be called “the wolf”.
Michael Lang
@mwlang
Jan 29 2015 20:55
I couldn't for the life of me get unixodbc and freetds configured and working, so I fell back on tiny_tds which required only freetds working.
"the wolf"? that's a new one to me.
Ken Collins
@metaskills
Jan 29 2015 20:56
From Pulp Fiction
Solving problems.
Michael Lang
@mwlang
Jan 29 2015 20:57
Ah. Looong time since I saw that movie.
Ken Collins
@metaskills
Jan 29 2015 20:57
@sgrif Isnt Rails 4.2 only for 2.0 or higher?
Sean Griffin
@sgrif
Jan 29 2015 20:57
No
Michael Lang
@mwlang
Jan 29 2015 20:57
1.9+
Sean Griffin
@sgrif
Jan 29 2015 20:57
5.0 will be 2.2+, 4.2 supports 1.9.3
Ken Collins
@metaskills
Jan 29 2015 20:57
Ah ha. OK, let me fix my include syntax.
Michael Lang
@mwlang
Jan 29 2015 21:10
Since I happened to be thinking about it just now, I went ahead and published that project... https://github.com/mwlang/activerecord-with-tinytds-adapter
there might be a couple hacks in there you might find useful now, but I kinda doubt it.
Ken Collins
@metaskills
Jan 29 2015 21:11
Wow, flash back.
May I suggest you add a README.md and/or do a blog post or or some news announcment on the repo.
Michael Lang
@mwlang
Jan 29 2015 21:11
I fixed a lot of bugs to get the activerecord unit tests passing, but not some of the more elaborate ones that had to do with nested subqueries.
Yeah, I figured I should.
people are going to stumble on this and go, WTF?
Ken Collins
@metaskills
Jan 29 2015 21:11
Idea is to allow Google to find this so others might find it and use it.
I used to be a marketing director :)
Michael Lang
@mwlang
Jan 29 2015 21:12
marketing director turned developer?
easier to build than to sell!
Ken Collins
@metaskills
Jan 29 2015 21:14
Indeed.
And designer before that.
Michael Lang
@mwlang
Jan 29 2015 21:15
ok, well I need to go for now. I'd like to see this project continue to support older SQL Server so I may get involved from that aspect. For now, I'm moving cross-country, so my corner will be pretty quiet for a month or so.
as it is, I end up adopting old gems and porting them when I take up new contracts, so might as well start figuring out better ways to pay that effort forward.
Ken Collins
@metaskills
Jan 29 2015 21:17
Cheers, travel safe.
Ken Collins
@metaskills
Jan 29 2015 21:32
Signing off for the evening.