Displaying 20 results from an estimated 1000 matches similar to: "Solr Search with one to many associations"
2011 Sep 04
0
should validate_numericality_of with greater_than_or_equal_to
Hello,
I have this in my spec
it { should
validate_numericality_of(:amount).greater_than_or_equal_to(0) }
but I get error:
Failure/Error: it { should
validate_numericality_of(:amount).greater_than_or_equal_to(0) }
NoMethodError:
undefined method `greater_than_or_equal_to'' for
#<RSpec::Matchers::Matcher:0xef23150>
this page
2008 Apr 08
0
Help building view to pass query to controller
I am very new to programming and would like to configure the following:
I want to configure a page that displayes some graphs. These graphs
pull its data from a sql table. What I would like to do is configure a
view .erb to have a search field that will take text and inject it to
part of a pre-configured sql query I have setup in a model. I will try
to explain as best I can with code.
2004 Nov 20
0
ffmpeg2theora start and end time support - patch
After posting my previous mail, I realized that i should instead post a
patch against HEAD. This is because v0.12 was released while I was also
changing ffmpeg2theora.c from v0.11. So please use this patch instead and
apply it to version at http://svn.xiph.org/trunk/ffmpeg2theora
Nilesh Bansal
http://www.cse.iitb.ac.in/nilesh/
-------------- next part --------------
Index: ffmpeg2theora.c
2006 Sep 22
2
I''m misunderstanding how stubs works
We''re still just starting out with Mocha/Stubba, so please forgive any
newbie errors.
I''m using "stubs" to test some realtime functions, to control exactly which
time is returned from Time.now. I would expect the following test to pass:
def test_two_stubs
t = Time.now - 60
Time.stubs(:now).returns(t)
start_time = Time.now
t += 20
2006 Apr 27
0
DRY validation
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi all,
A few months ago someone posted a message about specifying validates_*
constraints on a per-attribute basis. I just created a small plugin
that
allows you to do this.
Here''s an example from one of my models:
class Country < ActiveRecord::Base
attribute :name, :string do |a|
a.validates_length :within =>
2011 Dec 02
20
Need Some Guides on Solr with Rails.
Hi Everyone,
I am pretty new to Rails. I have very little idea about everything. But
for my new project i have been asked to do some research on Solr search
and implement it on Rails. Please provide me some link on tutorials and
guides about Solr on Rails. Trouble is... have to do it by tomorrow.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are
2007 May 31
0
background worker just stops running after some time
Hi,
I am fairly new to ruby/rails, but I thought I did a fair job of setting up
my background worker, but after some time, maybe 4-5 hours of running, it
just stops running, without any messages. Here is the yml file:
backgroundrb.yml
---
:port: 2000
:rails_env: production
:host: localhost
here is my schedules file:
alerts_task:
:class: :alerts_worker
:job_key: :alerts_key
2009 Mar 07
1
Cdr problem
hi,
I'm working with asterisk on a project and I found a problem with cdr_odbc.
As we know, after answering each call a cdr event is raised which is saved
in cdr_csv and cdr_odbc. but here my point is on cdr_odbc. some information,
including start_time and end_time is given by cdr event but the problem is
that these two information(start_time and end_time) is not getting save in
cdr_odbc. I
2014 Feb 21
5
[LLVMdev] interesting LLVM code optimization issue regarding timer registers
This problem was reported to me by a friend who has an LLVM port that is
not put back to open source.
Essentially, there is an intrinsic call _lr which is a load register.
so then user code has something like:
start_time = _lr(TIMER_REGISTER)
.....
some_code_to_time
....
end_time = _lr(TIMER_REGISTER)
So what happens is that LLVM moves the code as follows:
start_time = _lr(TIMER_REGISTER)
2013 Jun 22
4
ActiveRecord::Base.transaction - SystemStackError - stack level too deep:
Im having an issue that seems to only happen when trying to use a
transaction. Ive used transactions many times in the past and Im at a loss
as to why im getting the stack level too deep problem.
SystemStackError - stack level too deep:
actionpack (3.2.13) lib/action_dispatch/middleware/reloader.rb:70:in `''
I have a StackOveflow with more detail -
2015 Oct 20
1
[PATCH v3 07/13] v2v: factor out copying of output data
Factor out copying the overlays to final disk images into a separate
function.
Signed-off-by: Roman Kagan <rkagan@virtuozzo.com>
---
v2v/v2v.ml | 227 +++++++++++++++++++++++++++++++------------------------------
1 file changed, 114 insertions(+), 113 deletions(-)
diff --git a/v2v/v2v.ml b/v2v/v2v.ml
index afffde2..703038c 100644
--- a/v2v/v2v.ml
+++ b/v2v/v2v.ml
@@ -110,121 +110,9 @@ let
2008 Feb 11
0
Problem in passing params
Hi,
I have a controller called students_controller.rb
From a view file i am calling the index method by the URL like,
students_path(:format => :json)
I have no problem in that. But i want to pass the teacher_id as the
parameter. Like,
students_path(:format => :json, :teacher_id => 5)
The problem here is, the parameter is passing as,
"amp;teacher_id" => "5"
I
2004 Sep 01
1
sunspot data in R 2.0.0
I noticed this in the NEWS:
o Datasets 'sunspot.month' and 'sunspot.year' are available
separately but not via data(sunspot) (which is used by package
lattice to retrieve a dataset 'sunspot').
Now, the 'sunspot' dataset included in lattice was actually a mistake, I
realized later that I instead wanted the 'sunspots' data from
2007 Jul 10
0
Plot dies with memory not mapped (segfault) (PR#9785)
Full_Name: Clay B
Version: 2.5.0 (2007-04-23)
OS: Solaris Nevada Build 55b
Submission from: (NULL) (65.101.229.198)
I find that running this script causes R to segfault reliably. However, running
just for one system at a time (modifying the for loop updating iter to run just
for a system at a time works). The system is a Sun W2100z with 12 GB of ram, and
R segfaults using only around 360 MB of
2003 Jun 09
1
Questions for package ts prediction
Dear helpers,
I am trying to write a function to return prediction values using
package ts. I have written three different versions since I am not sure
what's wrong with my func2. func and func1 return the same results.But
func1 and func2 don't. In particular, the only difference between
"func1" and "func2" is the function variable name being y and data,
respectively.
2008 May 17
12
validates_numericality_of with greater_than* less_than* simply don't work
It seems that the validations for:
greater_than
greater_than_or_equal_to
less_than
less_than_or_equal_to
equal_to
odd
even
Simply do not work (Rails 2.0.2). I''ve tried every combination I can
think of and these never seem to fire.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails:
2007 Sep 07
5
unable to add IP address to eth0:0 eth0:1 etc
Hi all,
I need to (quickly!grrr) update IP addresses for which a given machine
will answer.
I did this:
/sbin/ifconfig eth0:0 xx.xx.xx.10 netmask 255.255.255.0
/sbin/ifconfig eth0:1 xx.xx.xx.11 netmask 255.255.255.0
/sbin/ifconfig eth0:2 xx.xx.xx.30 netmask 255.255.255.0
/sbin/ifconfig eth0:3 xx.xx.xx.31 netmask 255.255.255.0
/sbin/ifconfig eth0:4 xx.xx.xx.13 netmask 255.255.255.0
2007 Aug 16
1
SELinux questions, upon restarting BIND
Hi all,
On my newly up-and-running nameserver (CentOS 5), I noticed the
following alerts in /var/log/messages after restarting BIND. (lines
inserted to aid in reading).
As I'm new to SELinux, I'm hoping for some pointers on 1) if this is an
issue which simply *must* be addressed, or if it's something I should
live with, and 2) how to eliminate the warming messages without
sacrificing
2004 Nov 20
0
ffmpeg2theora start and end time support
For last few days I was trying to learn ffmpeg and libtheora API. In the
process, I have modified ffmpeg2theora code to include support for start
time and end time.
ffmpeg2theora -s 60 -e 130 file.avi
will produce file.ogg which will be from 60th to 130th second of input
file (something like -ss and -endpos in mencoder). This is a useful
feature for someone who wants to cut a part of video
2007 May 15
4
Need help with singleton worker
We have a fairly expensive task that we''d rather not schedule too many
instances of in parallel.
Couldn''t get pool_size to limit the amount of workers, and I figure
that''s hardly optimal anyway, so would like to have the work queued up
for a single named worker instead, running as soon as possible.
Using MiddleMan.schedule_worker() with :job_key does start off a