Open source RDBMS (relational database management system) when used in conjunction with the Ruby on Rails framework.
1
vote
1answer
13 views
Rails multitenant architecture, migrating from single-tenancy
We have a single-tenant database architecture at the moment with MySQL running upward of 100 databases. We switch database connection on subdomain using the Apartment gem and all is dandy!
However, ...
1
vote
1answer
32 views
RSpec, Rails 4, Postgres, UUID primary keys: id is null with Rake + RSpec, but is fine in RSpec or console
I'm trying to get up and running with UUID primary keys for a model with Postgres and Rails 4.0.0.rc2, but my specs are failing to create and destroy, yet MyThing.create or MyThing#destroy works fine ...
0
votes
2answers
36 views
Creating a scope to compare 2 dates
I have a model called Feed that records two timestamps, Last_visited and Last_modified.
I'd like to render a list of feeds where last_modified > last_visited
I currently have this scope in my model:
...
0
votes
1answer
33 views
Connection refused (PGError) (postgresql and rails)
I keep getting this error when i try to run my localhost using "$rails s":
(Mac OSX 10.8.3)
(ruby 2.0.0p195 (2013-05-14 revision 40734) [x86_64-darwin12.3.0])
(Rails 3.2.11)
(psql (PostgreSQL) ...
0
votes
0answers
45 views
Rails - PostgreSQL group by and order by another
I have a score model where users can play and add scores. When I pick the highscore I don't want to let users have more than one score on the scoreboard.
Therefore I need to sort the score by points ...
0
votes
0answers
48 views
$ rails db fails with error, but database is working fine
My Rails 3.2 app is using a PostgreSQL database. It's working great locally. I can migrate and interact with the application through the browser or irb.
However when I run $ rails db, I get an error: ...
0
votes
0answers
18 views
trigram search returning <PgSearch::ScopeOptions::DisableEagerLoading:0x3fce0aef3130>
In my NewContact model, I have the following:
pg_search_scope :contact_from_search, :against => [:first_name, :last_name, :email],
:using => {
...
0
votes
0answers
50 views
Rails + PostgreSQL: How Do I save TimeStamp Values?
I'm building an API on Rails w/ Postgres, and users will be sending GET, POST & PUT requests of timestamps. I will not be handling timezones. It's up to the users to submit in UTC. So, what ...
0
votes
1answer
37 views
Rails Heroku database missing data
I'm new to Rails and Heroku.
I don't partly understand system of databases (testing, production, development).
I created two Rails apps. First with Rails' default sqlite db and second with ...
0
votes
0answers
19 views
activerecord uncached method not working for postgresql
I have a rails app that uses postgresql and I want to temporarily disable query caching for the purpose of testing my query times.
The following solution works for sqlite database, but i have been ...
0
votes
0answers
27 views
Deploying app to Heroku - dm-core and dm-postgres-adapter issue?
I am having an issue deploying to Heroku - here is the strange line of my log file:
/app/vendor/bundle/ruby/1.9.1/gems/dm-core-1.2.0/lib/dm-core/adapters.rb:163:in 'require': no such file to load -- ...
0
votes
0answers
81 views
rails g scaffold! uninitialized constant in development environment
I got my ror development environment setup on ubuntu 10.04, using postgresql database. I was doing a test to generate a scaffold when I got:
<module:AppName>: uninitialized constant ...
1
vote
0answers
33 views
Rails item feed of distinct items shared by users followed by the current user
So I'm trying to make a feed of items in which the items are distinct, and each item can be shared by many users. My data model is:
User: has_many :postings, has_many :products, :through => ...
0
votes
0answers
19 views
Rails Join Table Issues
In my app there is an Athlete and this athlete has many sports (joined through a user_sports table). Now, each sport has a position (Pitcher, Third Base, etc).
Where I am stuck at is trying to ...
0
votes
0answers
51 views
radio button counter in database
Ruby on Rails beginner here.
extremely simple question.I have a form with 4 radio buttons. a,b,c,d.
everytime a user selects one of the four options and hits submit,i want the value incremented by 1 ...