[Ironruby-core] Updated Rails instructions
Jimmy.Schementi at microsoft.com
Wed Jan 20 17:21:43 EST 2010
> -----Original Message-----
> From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-
> bounces at rubyforge.org] On Behalf Of Sam Clopton
> Sent: Wednesday, January 20, 2010 12:49 PM
> To: ironruby-core at rubyforge.org
> Subject: Re: [Ironruby-core] Updated Rails instructions
> Bug noticed:
> Only with the new adapter (used igem install ...), only when I create a
> new row, the redirect below adds two 0's to the end of the new rows id
> (I.E. id = 56, it will try to show 5600). Switched back to the old
> adapter (at work) for now.
> @company = Company.new(params[:company])
> if @company.save
> flash[:notice] = "Successfully created company."
> redirect_to company_path(@company)
I'm not seeing this; the scaffolding example at the link below does the same thing, and redirects fine with the new adapter (a Post created with the id "4" will redirect to "/posts/4"):
@post = Post.new(params[:post])
flash[:notice] = 'Post was successfully created.'
render :action => "new"
Can you possibly send more information with the old adapter? I'd like these lines added right after @company.save succeeds (inside the "if" statement), and then could you send the output?
> Jimmy Schementi wrote:
> > All,
> > http://ironruby.net/Documentation/Rails has been updated to show
> > instructions for running Rails 2.3.5 on IronRuby, including using the
> > official activerecord-sqlserver-adapter (v2.3). Thanks to Ivan for his
> > work on ironruby-dbi!
> > The steps are extrememly simple now. Assuming you have IronRuby
> > installed and a Rails app you'd like to run on IronRuby:
> > 1. Install Rake, Rails, and IronRuby SQLServer
> > igem install rake rails ironruby-sqlserver
> > 2. Add the following to the top of your app's config/environment.rb:
> > require 'rubygems'
> > require 'ironruby_sqlserver'
> > 3. Connect to SQLServer in config/database.yml:
> > development:
> > mode: ADONET
> > adapter: sqlserver
> > host: YOURMACHINENAME\SQLEXPRESS
> > database: app123_development
> > integrated_security: true
> > 4. Migrate the database and start the server:
> > irake db:migrate
> > ir script\server
> > And that's it! The documentation link above also has a walk through
> > setting up IronRuby, Rails, and SQLServer, and shows a basic Rails
> > "scaffold" running.
> > Coming soon are updated instructions for running rack-based web
> > applications in IIS on IronRuby.
> > Let me know if you have any questions,
> > ~Jimmy
> Posted via http://www.ruby-forum.com/.
> Ironruby-core mailing list
> Ironruby-core at rubyforge.org
More information about the Ironruby-core