cn w update d two tables under one .. action.....both tables r in one to one relation

i hav tried this thng.....but it s coming to the else part.

class Article < ActiveRecord::Base
belongs_to :category

class Category < ActiveRecord::Base
has_one :article

def update
    @article =
   @article.uploaded_data = (params[:article])
    @article.article = Article.find(params[:id])
        @article.article.tag_list = (params[:tag_list])
       if @article.update_attributes(params[:article])
         redirect_to :action => 'show', :id => @article
        @categories = Category.find(:all)
        render :action => 'edit'


Joe, you have posted to the wrong group. These questions belong here:

or on the Rails forum:

And while you are asking your questions there, please try and write full words and sentences in English language so that people can understand your questions and answer them. Thanks.