Displaying 20 results from an estimated 1000 matches similar to: "Patch for #3438: Eager loading doesn''t respect :order of associations"
2006 Jul 23
0
[PATCH] (+tests) with_scope :order doesn''t work with included associations
(I''ve had this patch lying around for a couple of weeks, waiting for
Trac to come back up. noradio''s already had a look at it on IRC.
What''s the best way to submit patches while Trac is down?)
with_scope doesn''t support :order in the presence of :include. For
example:
{{{
# We''re testing the interaction between :order, :include, and
2010 Aug 05
3
how to ? Rails 3 ActiveRecord eager loading and AREL
Hello everyone,
I would like to eager load scoped records to avoid queries executed in a
loop (huge performance impact).
The "scoped" part is what is giving me a hard time.
I''m using Rails3 RC.
Does anyone have any idea how I can do it?
Here is a test case : we have an "Article" and a "Comment" Activerecord
models,
article has many comments
comment
2006 May 27
0
Typo 1055 created_at Vs. published_at
[Couldn''t post this to the Typo forum, hope it''s Ok here :-)]
Before I go off and create a Typo ticket, I''d like to know if anyone
else is experiencing this and what there thoughts might be on the
subject?
In Typo 1055, if you use the admin interface and change the published
date for an article, you will get "post not found", when you click on
the article
2010 Apr 12
2
[PATCH] Access to more Arel predicate types from where condition hash
I could use some eyes on https://rails.lighthouseapp.com/projects/8994/tickets/4368
if anyone has the time.
Summary of the change:
Similar to PredicateBuilder''s existing support for ''table.column'' =>
''value'', this patch enables ''column#method'' => ''value''.
For instance,
2012 Apr 17
6
ActiveRecord with different Date/Time format
I have an application where user sets his/her preferred date/time
format. User is expected to enter datetime in his preferred format
across the application. Now the problem is for few formats the datetime
is parsed wrongly while create/update ActiveRecord.
For example user has set date/time format in hh:mm dd/MM/yyyy. Now if
user enters 17:00 04/05/2012 it parses it as 5 PM 5 Apr, 2012 where it
2006 Jan 03
0
has_and_belongs_to_many include problem
hey,
i have users who are in groups, and i have a search form, where i can search on
group, user lastname, and user firstname.
All this is also with pagination.
these are my models
class User < ActiveRecord::Base
has_and_belongs_to_many :groups
end
class Group < ActiveRecord::Base
has_and_belongs_to_many :users
end
in my controller i do this
THIS works (but in need pagination)
@users2
2006 Jul 24
7
[PATCH] Support for DB Clusters/Replication in ActiveRecord (RFC)
Skipped content of type multipart/alternative-------------- next part --------------
Index: connection_adapters/abstract/connection_specification.rb
===================================================================
--- connection_adapters/abstract/connection_specification.rb (revision 4617)
+++ connection_adapters/abstract/connection_specification.rb (working copy)
@@ -1,10 +1,21 @@
require
2011 Aug 21
0
problem with typo6.0.8
hi all
i am using typo6.0.8 in rails3..
when i click on articles tab of typo admin page in browser.. i get the
following error.. and all the remaining tags are working fine.
undefined method `gsub!'' for 2011-08-21 06:28:15 UTC:Time
Extracted source (around line *#34*):
31: %></td>
32: <td><%= collection_select_with_current(:search, :user_id,
User.find(:all),
2009 Mar 26
0
acts_as_versioned and qa
Hi,
I have Article model and it has aasm_column qa, that is initially
"pending".
In order to get it reset qa column on new versions, I have made:
def set_new_version
write_attribute(:qa, "pending")
end
But now the aasm methods are also triggering the new version, dispite:
self.non_versioned_columns << ''updated_at''
2007 May 31
0
Rails AR/SQLServer Unit Test: [6912] failed (but getting better)
"bitsweat" has given AR/SQLServer some love, but it''s still unhappy...
http://dev.rubyonrails.org/changeset/6912
------------------------------------------------------------------------
r6912 | bitsweat | 2007-05-31 10:15:56 -0700 (Thu, 31 May 2007) | 1 line
Fix an edge case with find with a list of ids, limit, and offset. Closes #8437.
2006 Apr 20
5
acts_as_taggable patch 3866 needs some testing
DHH''s acts_as_taggable is now much more usable with this patch.
http://dev.rubyonrails.org/ticket/3866
This patch adds scoped finders, documentation, and tests:
# Get tags for all articles in a blog
@blog.articles.tags
# Get tags for articles in a blog published in the last year
@blog.articles.tags :conditions => [''published_at > ?'', 1.year.ago]
# Get related
2009 Jul 28
1
Rails date conversion
The environment.rb file in a Rails 2.3.2 app says:
> Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
Auto-convert to this zone... when?
Also, what are the differences between these two statements?
config.time_zone = xxx
config.active_record.default_timezone = xxx
I ask these questions because I have a scenario whereby an AR-backed
object, when
2008 Jul 30
2
Mysql "lock wait timeout" tuning
We''re seeing these errors intermittently:
###
Mysql::Error: Lock wait timeout exceeded; try restarting transaction:
UPDATE `chairs` SET `published_at` = NULL, `updated_at` = ''2008-07-30
15:31:05'' WHERE `id` = 2147
[RAILS_ROOT]/vendor/rails/activerecord/lib/active_record/
connection_adapters/abstract_adapter.rb:147:in `log''
###
The root issue is probably
2004 Aug 06
1
how to cut very big mp3s ?
On Sun, 6 Jan 2002, Jack Moffitt wrote:
> I think you're only solution is to convert to .wav do your editing, and
> then recompress (for mostly voices you'd probably want to downsample
> etc).
OK, that's what Audacity does, but unfortunately the version I've tried
breaks with big files (it shouldn't however because it cuts work files
in many small chunks)
> Out
2020 Jul 28
0
Assistant Clinical Professor - University of Maryland
The University of Maryland?s University Honors program invites applications
for four faculty positions to begin in Fall 2020. Each of these Assistant
Clinical Professor positions offers a three-year, full-time appointment
with competitive salaries and generous benefits. These faculty positions
offer a rare opportunity to incubate and test innovative pedagogy,
co-design and independently teach
2022 May 21
4
[Bug 3438] New: env var that is SetEnv'ed multiple times in the same SetEnv directive, is sent/printed several times
https://bugzilla.mindrot.org/show_bug.cgi?id=3438
Bug ID: 3438
Summary: env var that is SetEnv'ed multiple times in the same
SetEnv directive, is sent/printed several times
Product: Portable OpenSSH
Version: v9.0p1
Hardware: Other
OS: Linux
Status: NEW
Severity: normal
2015 May 13
0
[CentOS-announce] CEEA-2015:0958 CentOS 5 openssl Enhancement Update
On Wed, May 13, 2015 at 03:15:43PM +0000, Johnny Hughes wrote:
> CentOS Errata and Enhancement Advisory 2015:0958
>
> Upstream details at : https://rhn.redhat.com/errata/RHEA-2015-0958.html
Awww... and there I was hoping they'd finally backported TLS1.2. But,
nope, just a newer CA list. Ah well :-(
--
rgds
Stephen
2015 Dec 23
0
Starting stunnel on boot with CentOS7
On Tue, Dec 22, 2015 at 12:09:14PM -0600, Leroy Tennison wrote:
> The stunnel package doesn't come with an init script and systemctl
> doesn't list it as a service I recognize, I guess I could put it in
> /etc/rd.d/rc.local or create a script in /etc/rc.d/init.d but
> thought I'd ask before creating my own solution.
stunnel wraps a plaintext service in an SSL session.
2011 Feb 05
3
ActiveModel::AttributeMethods limiting
In my attempt to add AM:Dirty to my model I realized that
AM#AttributeMethods is a bit imperfect. It''s impossible to generate
attribute methods step-by-step in DataMapper-like manner.
class Model
include ActiveModel::Dirty
def self.property(name, klass = String)
define_property_accessors(name, klass)
# This method will be called once, because of
2007 Nov 29
4
collection.build or collection.create gives "ArgumentError: wrong number of arguments (1 for 0)"
I have a Project that has_many Tasks. Tasks belongs to a Project. When
I try the following:
project = Project.new
project.tasks.build
I get:
>> s = Project.new
=> #<Project:0x25f9e28 @attributes={"name"=>"", "end_at"=>nil,
"updated_at"=>nil, "published_at"=>nil, "user_id"=>nil,