Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9022591
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T05:33:03+00:00 2026-06-16T05:33:03+00:00

I am using RailsAdmin and this is the error I get when I click

  • 0

I am using RailsAdmin and this is the error I get when I click on my model CategoryProduct within RailsAdmin.

This is what the error looks like:

Started GET "/admin/category_product" for 67.230.41.62 at 2012-12-21 23:20:07 +0000
2012-12-21T23:20:07+00:00 app[web.1]: 
2012-12-21T23:20:07+00:00 app[web.1]: ActionView::Template::Error (PG::Error: ERROR:  column category_products.desc does not exist
2012-12-21T23:20:07+00:00 app[web.1]: LINE 1: ...ry_products".* FROM "category_products"  ORDER BY category_p...
2012-12-21T23:20:07+00:00 app[web.1]:                                                              ^
2012-12-21T23:20:07+00:00 app[web.1]: : SELECT  "category_products".* FROM "category_products"  ORDER BY category_products. desc LIMIT 20 OFFSET 0):
2012-12-21T23:20:07+00:00 app[web.1]:     120:       %tbody
2012-12-21T23:20:07+00:00 app[web.1]:     121:         - @objects.each do |object|
2012-12-21T23:20:07+00:00 app[web.1]:     122:           %tr
2012-12-21T23:20:07+00:00 app[web.1]:     123:             %td
2012-12-21T23:20:07+00:00 app[web.1]:     124:               = check_box_tag "bulk_ids[]", object.id, false
2012-12-21T23:20:07+00:00 app[web.1]:     125:             - if @other_left_link ||= other_left && index_path(params.except('set').merge(params[:set].to_i != 1 ? {:set => (params[:set].to_i - 1)} : {}))
2012-12-21T23:20:07+00:00 app[web.1]:     126:               %td.other.left= link_to "...", @other_left_link, :class => 'pjax'^

These are my category, product & category_product models:

Category.rb

# == Schema Information
#
# Table name: categories
#
#  id         :integer          not null, primary key
#  name       :string(255)
#  created_at :datetime         not null
#  updated_at :datetime         not null
#

class Category < ActiveRecord::Base
  attr_accessible :name
    has_many :category_products do
         def with_products
           includes(:product)
         end
       end

  has_many :products, :through => :category_products

  def top_products(number)
    category_products.with_products.order("purchases_count DESC").limit(number).map {|c| c.product} # product included
  end

end

Product.rb

# == Schema Information
#
# Table name: products
#
#  id          :integer          not null, primary key
#  name        :string(255)
#  description :string(255)
#  price       :float
#  vendor_id   :integer
#  created_at  :datetime         not null
#  updated_at  :datetime         not null
#  image       :string(255)
#

class Product < ActiveRecord::Base
  attr_accessible :name, :description, :price, :vendor_id, :image, :category_ids
    mount_uploader :image, ImageUploader

    belongs_to :vendor
    has_many :category_products do
           def with_categories
             includes(:category)
           end
    end

    has_many :categories, :through => :category_products

  def top_categories(number)
    category_products.with_categories.order("purchases_count DESC").limit(number).map {|c| c.category} # category included
  end

end

Category_Product

# == Schema Information
#
# Table name: category_products
#
#  id              :integer          not null, primary key
#  product_id      :integer
#  category_id     :integer
#  purchases_count :integer          default(0)
#  created_at      :datetime         not null
#  updated_at      :datetime         not null
#

class CategoryProduct < ActiveRecord::Base
  attr_accessible :product_id, :category_id, :purchases_count

    belongs_to :product
  belongs_to :category

  validates_uniqueness_of :product_id, :scope => :category_id
end

Any ideas what may be causing this?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T05:33:05+00:00Added an answer on June 16, 2026 at 5:33 am

    Turns out the problem was on Heroku’s side (I assume).

    I did another push with a different update to the codebase and this problem seemed to go away.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using range() in Underscore I can make something like this: _.range(10); >> [0, 1,
Im using Devise + CanCan and would like to redirect to my admin interface
when using rails_admin for associated objects (like has_and_belongs_to) it shows the ID of the
I'm trying to install the Rails Admin Gem using Sorcery for authentication instead of
using this http://bl.ocks.org/950642 we can see how to add images to nodes, the question
Using CI for the first time and i'm smashing my head with this seemingly
Using the Redis info command, I am able to get all the stats of
Using Location.getBearing(); I seem to get randomly changing bearings. Aka, I can turn the
I am using railsadmin for content management. I want to add 2 new laguages
Using RestKit 0.10.1, I have objects served similar to this json format: {objects: [

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.