Hi, I''m starting the first $realjob project with RoR and I''m bumping into a few roadblocks. It seems support for DB/2 is almost non-working; I''m wondering how many people, if any, are using it. The issues I''m seeing are manyfold: - queries are being constructed with single quotes around numeric values, this is not ok with DB/2, but it looks like it''s fine with MySQL. I''m not sure if this is a real issue or if it''s a side effect of the next item; - there is no support for schemas; a workaround is to use: set_table_name "schema:tabname" in the model, but this fails later when calling SQLColumns to determine column info; - add_limit_with_offset! is not implemented, meaning that there is no way of getting pagination to work. Alas, this is due to limitations of IBM SQL syntax, so something like what is in sqlserver_adapter.rb. Did anyone get DB/2 to work? How did you overcome the above issues? If not, I might try fixing them, but I''d need assistance; is anyone willing to mentor me, or is there someone not on the list I should talk to wrt activerecord? Bye, Andrea -- Press every key to continue.
Andrea Campi wrote:> - queries are being constructed with single quotes around numeric values, >this is not ok with DB/2, but it looks like it''s fine with MySQL. I''m not >sure if this is a real issue or if it''s a side effect of the next item; > > - there is no support for schemas; a workaround is to use: > set_table_name "schema:tabname" >in the model, but this fails later when calling SQLColumns to determine >column info; > > - add_limit_with_offset! is not implemented, meaning that there is no way of >getting pagination to work. Alas, this is due to limitations of IBM SQL >syntax, so something like what is in sqlserver_adapter.rb. > > >Did anyone get DB/2 to work? How did you overcome the above issues? If not, >I might try fixing them, but I''d need assistance; is anyone willing to >mentor me, or is there someone not on the list I should talk to wrt >activerecord? > > >These are exactly the same problems which stopped me from continuing to develop a decent ODBC driver. I think the best thing you can do right now is file a ticket in the bug system and start working on fixes in AR (namely the way SQL validation and quoting is done). I''ll second you where I can but I''m also just a beginner in the rails arena. Best regards, Bas
Hi, On Mon, May 16, 2005 at 11:29:21AM +0200, Andrea Campi wrote:> Did anyone get DB/2 to work? How did you overcome the above issues? If not, > I might try fixing them, but I''d need assistance; is anyone willing to > mentor me, or is there someone not on the list I should talk to wrt > activerecord?I went and fixed the main issues I was seeing, if you are interested you can try the attached patch. I also went and entered a ticket (#1383). I didn''t stress this too much, but it definitely is an improvement. Comments? Bye, Andrea -- Press every key to continue. _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails