Hello, I needed to add temporary table support in activerecord- oracle_enhanced-adapter (http://github.com/rsim/oracle-enhanced) for the project I''m working on. For some reason the syntax to create a temp table in Oracle is ''CREATE GLOBAL TEMPORARY TABLE'' - but ActiveRecord::ConnectionAdapters::SchemaStatements#create_table has it as ''CREATE TEMPORARY TABLE'' without any way of configuring it. This forced me to override the create_table method in the oracle adapter in order to apply the feature. I was not able to determine that ''CREATE TEMPORARY TABLE'' is any sort of standard (at least, I couldn''t find anything defining it in ANSI). I''m considering submitting a patch to make the syntax configurable somehow. Before I even bother doing that, I was hoping to get some feedback - i.e. whether or not this will be shot down from the get- go. Thanks! Billy Reisinger -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
On Thu, Dec 31, 2009 at 1:57 PM, uncle_billy <billy.reisinger@gmail.com>wrote:> somehow. Before I even bother doing that, I was hoping to get some > feedback - i.e. whether or not this will be shot down from the get- > go.The Oracle adapter is external to the rails code base now. I recommend you fork the rsim github code, apply your patch with tests and do a pull request. As someone who has used Rails with Oracle, I feel your pain and would love to see some points like this fixed. Re the ANSI standard, as you are coding the oracle adapter, then this really a moot point, what works with Oracle works for Oracle. If you need to patch rails to make it more database agnostic, I would think now is a good time to do it :) Mikel -- http://lindsaar.net/ -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
Mikel... I did fork oracle_enhanced to add this feature. I''m mostly concerned because I had to redefine create_table without calling super at all. Is this a valid concern? On Jan 1, 6:32 am, Mikel Lindsaar <raasd...@gmail.com> wrote:> On Thu, Dec 31, 2009 at 1:57 PM, uncle_billy <billy.reisin...@gmail.com>wrote: > > > somehow. Before I even bother doing that, I was hoping to get some > > feedback - i.e. whether or not this will be shot down from the get- > > go. > > The Oracle adapter is external to the rails code base now. I recommend you > fork the rsim github code, apply your patch with tests and do a pull > request. > > As someone who has used Rails with Oracle, I feel your pain and would love > to see some points like this fixed. > > Re the ANSI standard, as you are coding the oracle adapter, then this really > a moot point, what works with Oracle works for Oracle. > > If you need to patch rails to make it more database agnostic, I would think > now is a good time to do it :) > > Mikel > > --http://lindsaar.net/-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
> Mikel... > I did fork oracle_enhanced to add this feature. I''m mostly concerned > because I had to redefine create_table without calling super at all. > Is this a valid concern?That does seem a little shitty. Take a look at refactoring the method in AR to make it easier for you to selectively override rather than just reimplement the whole thing. Assuming the patch isn''t too intrusive we can apply it. -- Cheers Koz -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.