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

  • Home
  • SEARCH
  • 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 6737923
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T11:18:21+00:00 2026-05-26T11:18:21+00:00

I am unable to access a database table in rails. I am using ruby

  • 0

I am unable to access a database table in rails. I am using ruby 1.8.6 (2010-09-02 patchlevel 420) and Rails 2.2.2

"ActiveRecord::Base.connection.table_exists? Modelname.table_name"   returns true
"ActiveRecord::Base.connection.table_exists? Modelname"        returns false

When i say Modelname.create i am getting the “ORA-02289: sequence does not exist” error message.My model class looks like the below one.

class Modelname < ActiveRecord::Base
end

I have created the table using sql statement instead of migration. Can anyone please let me know why i am facing this problem.

  • 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-05-26T11:18:22+00:00Added an answer on May 26, 2026 at 11:18 am

    The expectation of Rails is that your model table name is pluralized (because it stores more that one entity), your model name is singularized. You may override that like explained in the API of ActiveRecord by using the following:

    class Modelname < ActiveRecord::Base
      set_table_name "modelname" ## if that is your name of the table
    end
    

    It was not clear from your question what your table name is.

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

Sidebar

Related Questions

How do I allow a function to access a database connection without using GLOBAL?
I'm accessing a Microsoft Access 2002 database (MDB) using ASP.NET through the OdbcConnection class,
I'm getting System.Data.SQLite.SQLiteException: Unable to open the database file. when I attempt to access
I have a SQLite Database that I access using System.Data.SQLite . The database is
Error: Unable to read data from the transport connection: A blocking operation was interrupted
I'm trying to clean up a database table and I'd really like to drop
In this live SQL Server 2008 (build 10.0.1600) database, there's an Events table, which
I'm trying to create a query in an access database for a C# dataset
I'm trying to restrict access to a database on my server to only allow
i have to create reports with certain data from an access database. i want

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.