Displaying 20 results from an estimated 700 matches similar to: "NoMethodError: undefined method `more_results' for #<Mysql>"
2011 Jan 06
4
Not able to insert value in rails console
I am using authlogic for authentication in rails 3.0.3 with ruby 1.9.2
Using activerecord-sqlserver-adapter (3.0.5)
windows with sqlserver database
when i create user details in rails console, i am getting below error,
>User.create(:login=>''test'',:password=>''test123'',:password_confirmation=>''test123'')
2013 Mar 28
1
undefined method 'sanitize_limit' for #<ActiveRecord::Relation:0x2aaaad35d720>
I am trying to upgrate rails from 3.0 to 3.1, while updating rails version
I am getting following error
rake aborted!
undefined method `sanitize_limit'' for
#<ActiveRecord::Relation:0x2aaaad35d720>
/some_package/lib/ruby/gems/1.8/gems/activerecord-3.1.12/lib/active_record/relation.rb:460:in
`method_missing''
2011 Jul 26
0
active record wants root password, not sure why ..
When I run a command program (rails 3/ruby 1.9.2) as this:
class MsdsAttr < ActiveRecord::Base
include MsdsAttrModule
belongs_to :attribute_record, :polymorphic => true
has_many :attribute_values, :foreign_key => ''attribute_id''
has_many :alt_values, :as => :alternative
has_many :msds_ingredients
end
ActiveRecord::Base.establish_connection(
:adapter =>
2012 Dec 15
7
Re-imagined README.md for rails applications
Most of the time I use readme.md file to explain how to properly install
the dependencies and run the application for first time. I use [something
like](https://gist.github.com/3058000) as a README.md scaffold.
Just an idea, What would you guys think about replacing the current readme
with something like this?
https://gist.github.com/3058000
Oguz Bilgic
Thanks
--
You received this
2006 Mar 28
0
Sql error using MAMP with rails 1.1
Hi,
I am newbie and i am using MAMP with rails for trying out few things in
web development.
I just upgraded to rails 1.1 and created a new rails depot project and
when i just gone to change my database.yml, I get this
-------------------------------------------------------------------------------
development:
adapter: mysql
database: depot_development
username: root
password: root
2010 Mar 26
2
Fix for the consume_results leak
I'm not really comfortable with making non-trivial changes to this
code but here is at least a fix for the PGresult leak (verified to
both apply to 1.2.11 and 2.0.beta4).
-----
--- dovecot/src/lib-sql/driver-pgsql.c 15 Mar 2010 18:18:14 -0000 1.1.1.2
+++ dovecot/src/lib-sql/driver-pgsql.c 26 Mar 2010 14:13:18 -0000 1.1.1.2.4.1
@@ -247,6 +247,17 @@
return 0;
}
+static inline int
2008 Sep 19
2
Using Rails on MAMP via Passenger?
I''m new Ruby as well as the Rails Framework. I want to install
Passenger so that I can develop in MAMP (Leopard), but I can''t find
any instructions specific to installing Passenger on MAMP.
Can anyone provide with me instructions on how to do so?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
2008 Oct 07
0
Rails Deployment Using Passenger (Problems)
Hello,
I have been trying to deploy my Rails application using Passenger on
my local machine that runs Mac OS X Tiger. I saw the screencast by
Ryan Bates and also referred to benr75[http://benr75.com/articles/
2008/04/12/setup-mod_rails-phusion-mac-os-x-leopard] for specific
instructions for Mac (but they are for leopard).
Right now if I go to http://localhost all I get is "It Works!".
2011 Sep 18
9
Rails 3 and postgresql
I have a simple project created around a very, very simple database: one
main table packs with just three rows
Column | Type |
Modifiers
--------+-----------------------------+----------------------------------------------------
id | integer | not null default
nextval(''packs_id_seq''::regclass)
nombre | character
2007 Aug 14
1
find_by_sql vs connection.select_all
I was trying to do SUM based mySQL query simliar to the following:
SELECT SUM(updated_on - created_on) AS total from signups
If I were to run this command in the mySQL console I would get a
result. However, if I were to run it using the following command in
Rails:
Signup.find_by_sql("SELECT SUM(updated_on - created_on) AS total from
signups")
The query that is written to the log is:
2006 Jun 24
8
PostgreSQL on Mac?
Is there something like MAMP, but uses PostgreSQL instead? I found a
couple PostgreSQL dmg''s, but one was < 8.x. For those who use PostgreSQL
on Mac, how''d you install it (fink, package, please don''t say compile!)?
Thanks,
Joe
--
Posted via http://www.ruby-forum.com/.
2005 Apr 27
4
has_many syntax
Hi all,
I have the following inside of an AR class definition:
relationships=ActiveRecord::Base.connection.select_all(my_relationships_sql)
relationships.each do |relationship|
has_many RelatedItems, :class_name => relationship[''RelatedClass''],
:foreign_key => relationship[''ForeignKey'']
end
This kind of works, but how can I assign the name of the
2011 Jan 17
2
Accessing MySQL Database in R
I have a local installation of MySQL on my computer.
I enter the following to access MySQL from the command line:
/Applications/MAMP/Library/bin/mysql -h localhost -u root -p
I am then prompted for a password, and I use: root
This connects me to MySQL in the command line.
I now want to access MySQL databases in R. I enter the following:
mysql <- dbDriver("MySQL")
conn <-
2008 Mar 20
0
Mixing stored procedure call with RoR db calls in the same function gives errors
Folks,
I am using ruby 1.8.5 with rails 1.2.3 and have made changes to
mysql_adapter.rb based on recommendations made here
http://wiki.rubyonrails.org/rails/pages/StoredProceduresInMySql to be
able to use stored procs in my code.
I have changed this call in mysql_adapter.rb
ConnectionAdapters::MysqlAdapter.new(mysql, logger, [host, username,
password, database, port, socket], config)
to
2006 May 15
2
retrieving hashes key & values (ASAP)
Hi,
I want to retrieve the set of key & values which returns from a
stored procedure : connection.select_all "exec common.dbo.scr_lookupric
''AAP.N'' ".
The results i want to display in a view screen call result.rhtml.
Please help me out ASAP.
Thanks in advance.
joshua...
--
Posted via http://www.ruby-forum.com/.
2006 Jun 23
1
''Series'' Pluralization
Howdy,
I have a model I called ''content_series''. I created it and noticed that
Rails called it ''Sery'', so I added ''series'' to the uncountable thing in
the config, like this:
Inflector.inflections do |inflect|
# inflect.plural /^(ox)$/i, ''\1en''
# inflect.singular /^(ox)en/i, ''\1''
#
2006 Aug 07
0
MySQL Native Bindings
I was following the hivelogic.com article ''Building Ruby, Rails, LightTPD,
and MySQL on Tiger''
http://hivelogic.com/articles/2005/12/01/ruby_rails_lighttpd_mysql_tiger
all went well till the last part, MySQL Native Bindings.
http://weblog.rubyonrails.com/2005/10/30/get-10-15-more-performance-with-mysql-rails/
anyways, i recieved an error:
blinking8s:~ blinking8s$ sudo gem
2009 Apr 11
6
Inserting data from 1 table to another by using find_by_sql
Hi All,
I am inserting data from one table to another by using following method
@data=RoyaltyReportFiles.find_by_sql("insert into royalty_reports
(artist_name, album_name) select artist_name, album_name from
temp_royalty_reports where id=328417")
it saves the data into royalty_reports table but it gives following
error and application crashes. i am using rails 1.2.5
You have a nil
2006 Aug 17
6
NameError in AdminController#index building scaffold
I''m a pretty big newbie with ROR, but when following a tutorial I
encounter an ugly error when building a scaffold. Here is my
environment
Dev system:
- Windows XP
- java version "1.5.0_06"
- MySQL java version "1.5.0_06"
- Ruby 1.8.4
- Ruby Gems 0.9.0
- Gem install mysql
Successfully installed mysql-2.7.1-mswin32
Installing ri documentation for
2006 Jun 21
2
raw sql and columns order
Hi, I''ve a model with the following method:
def self.run(sql)
return connection.select_all(sql)
end
so, the value returned is an array of hashes... the problen is that the sql
command:
"select name, id from table"
and
select id,name from table"
returns the columns in the same order (name, id).
And in my view, I need to keep the order of the SQL command.