Open source RDBMS (relational database management system) when used in conjunction with the Ruby on Rails framework.
1
vote
0answers
35 views
Rails: Update a column with the value of a column in another table
I have basically the following code:
ModelA.join(:modelB).update_all('modelA.column = modelB.column')
That fails with:
ActiveRecord::StatementInvalid: PG::UndefinedTable: ERROR: missing ...
0
votes
1answer
17 views
Compare only the times of two timestamps in postgres
In PostgreSQL, I need a way to determine if the current time is within the hours of operation of a certain model with an opens_at and closes_at timestamp. What would be a valid Postgres way of doing ...
0
votes
0answers
33 views
Radio button selection Rails - Across partials
I am trying to allow the user to pick one of the predictions out of the 7/8 (which are loaded with the predictions partial) as a double match (double points for anyone interested). I can't get it to ...
1
vote
1answer
31 views
Too many database connections created in rails 2.3.18 application
We have many models like the below one.
class User < ActiveRecord::Base
create_connection
def create_connection
# we have used this ...
0
votes
0answers
42 views
digital ocean(ubuntu) - how many rails apps can be hosted in a 512mb plan (including others like nginx, postgres etc) [closed]
I am setting up some rails apps on digital ocean basic plan of 5$ per month offering 512mb memory. I just installed basic things like git, vim, nginx, postgres(along with contrib), rvm and now just ...
-1
votes
0answers
46 views
Heroku keeps telling me my application fails
So I am trying to push my site to heroku for the first time and some things have gone wrong. First was the postgres DB stuff so I added the gem for pg in the production group but it continues to say ...
-1
votes
0answers
29 views
Deploying to Heroku issues Rails 3.2
So i had an app that i initially developed in SQLITE and converted over to POSTGRESQL and it works fine locally. When I try to deploy to Heroku my web dynos crash when I try to visit my application. ...
1
vote
2answers
67 views
rails - does postgres or rails automatically validate that a datetime column can only have datetime object?
I have a rails 4 form in which a user inputs a string that represents a datetime:
<%= f.text_field :time_frame, class: "calender_pop" %><br />
No where in my code am I converting the ...
1
vote
0answers
31 views
Populating rails Database from Amazon RDS data
I currently am working on an inventory application(rails 4.0 on Heroku using PostgreSQL). I also have a database that tracks my sales on Amazon RDS using Sql Server 2008. I'd like to figure out a way ...
1
vote
2answers
66 views
PG::UndefinedTable: ERROR: relation «productsrules» does not exist
I'm having this issue with one of my PG DB table. I have a table, whose name is "hproducts_rules". This is supposed to have a "belongs_to" relation with the "hproducts_matchs" table.
This is my ...
0
votes
0answers
31 views
hstore on Heroku: can't iterate over hash members
I have an hstore attribute called properties. The following code puts a line break between each attribute before outputting it to the view.
def item_properties_to_string(item)
return nil unless ...
0
votes
0answers
44 views
Rails 4 polymorphic, self-join or ancestry?
I've got a Venue structure to create where you are able to place different types of components under different locations in the same Venue so the structures are like this:
Main Hall -> Conference ...
2
votes
2answers
41 views
Importing CSV into Postgresql with duplicate values that are not duplicate rows
I am using Rails 4 and postgresql database and I have a question about entering in a CSV dataset into the database.
Date Advertiser Name Impressions Clicks CPM CPA CPC CTR
10/21/13 ...
0
votes
0answers
109 views
postgresql gem with ruby 2.0.0-p353 on mac wont suceed
I'm trying to bundle a new rails app using Postgres.
I get this error each time I try to bundle.
Errno::EACCES: Permission denied - /usr/local/var/rbenv/versions/2.0.0- ...
0
votes
0answers
61 views
Rails select NoMethodError in Messages#new
I'm trying to put on a select box the Users who will receive the message.
What we have is one table named Messages, one named Users and one named Friendships, on message table we have user_id (sender) ...