similar to: Active Record save doesn''t save! (or throw an exception)

Displaying 20 results from an estimated 20000 matches similar to: "Active Record save doesn''t save! (or throw an exception)"

2006 Apr 28
2
Active Record save doesn''t save! (more detail - is this a bug?)
I got it to work by changing scheduled_end_date= nil to self.scheduled_end_date= nil. I believe these statements should be equivilent. I don''t know Ruby/Rails well enough to know when, if or why that should matter. Can someone educate me please? I want to believe this framework is ready for production work, but silently dropping data is a very big problem. I expect that I''ve
2006 Mar 09
4
sort-weirdness - active record issue?
I''m selecting data into a controller and sorting it. The code (in the controller) looks like this: def index @assignments = [] tasks = Task.find(:all, :conditions => ["person_id = ? and actual_end_date is null", session[:user].id.to_s ]) issues = Issue.find(:all, :conditions => ["person_id = ? and status <>
2006 Apr 01
5
What IDE for Rails on OSX?
Hi, I''m using TextMate for rails development on OSX, but have reached a point where I need to run in a debugger and be able to step through the code as it executes. I have previously used the Eclipse Ruby plug in and another IDE for ruby development on windows, but never figured out how to run a Rails app in the debugger. How are other textmate users debugging and what else is there on
2006 Mar 09
3
Building a model from a database view
Hi, I''m trying to use rails to build a model from a database view. I get this output C:\dev\v6\project>ruby script/generate scaffold Assignment ... error Before updating scaffolding from new DB schema, try creating a tab le for your model (Assignment) Is this not possible in Rails? It would be *really* helpful for my application. -------------- next part -------------- An
2006 Mar 23
3
drag and drop sorting recipe
The new pragmatic Rails Cookbook has a drag and drop sorting recipe. Does anyone know if this works with 1.0? I''ve followed the recipe (i think), and I can drag but when I drop everything goes back the way it was. It seems that the sort logic doesn''t get invoked. I put this code in my view: <%= sortable_element ''task-list'' , :url => {
2006 Apr 28
0
RE: Rails Digest, Vol 19, Issue 784
I am having a bit of trouble with the error. I hava a product and category table and wanting to display the categories in a drop down list. Below is the error I get. Any suggestion on how I can fix this. undefined method `name'' for #<Category:0x3652448> 9: <select name="product[category_id]"> 10: <% @categories.each do |category| %> 11:
2006 Mar 11
2
how do i retrieve a newly created id
in my code i''m calling save on an object. The id gets created as the object is persisted. How can i retrieve that newly created id? I guess I could query the table again using the other attributes of the object but is there another way? thanks in advance. larry -------------- next part -------------- An HTML attachment was scrubbed... URL:
2006 Mar 10
3
installing rails 1.0 on Windows
I ran the gem installer and it seemed to work, but i believe i''m still using an older version. How can i tell what version I''m really using? Thansk -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060310/435006b0/attachment.html
2005 Mar 24
3
summing values by group
At the risk of being wacked for asking what should be obvious.... I have a data frame with one categorical variable "CAT" and several numeric variables. I want to be able to get simple statistics on the numeric variables by level. For example, just as you can use table (CAT) to get the counts, I'd like to be able to get the means and sums by category. If someone could point me
2006 May 01
2
how to reference a file for download
I have an app that uploads files into the directory RAILS_ROOT/documents/ I tried to access the file for downloading using <a href="#{RAILS_ROOT}/documents/file_name">my file</a>. Rails prepends the controller name to the link so I get <a href=" http://localhost:3000/tasks/show_document/config/.../documents/file_name" What''s the right way to do this?
2006 Aug 06
2
file upload with form_remote_tag
Is there a way to use form_remote_tag and to upload a file? The default behavior ignores the upload when the Javascript serializes the form to create the parameter list. Basically, i''m just looking for an ajax file upload capability. Any help would be appreciated. thanks. -------------- next part -------------- An HTML attachment was scrubbed... URL:
2009 Sep 19
3
reducing space between charts in lattice graphics
Hi, I'm trying to create a lattice plot with three xyplots in one vertical column. I would like to reduce the vertical space between the charts. My code is below. There seems to be a "between" parameter for lattice.options, but I can't find any examples. Aside from the data setup, the code is below. Can anyone provide an example showing how to reduce the white space between the
2009 Sep 14
1
dates with lattice graphics
Hi, I'm trying to do something simple (I think) with lattice graphics. I want to have three xyplots in a single column, where the x axis for the three is a date range and the y axes are numeric. I tried doing the first chart, and ran into a problem. When I enter: xyplot (date ~ count) I get a well formed plot with the date on the y axis, but when I enter: xyplot (count ~ date) I get:
2009 Sep 23
1
percent data being treated as categorical
I have the following data exported as a .txt file on Windows. Everything is working fine, except that the the data in the 10th column is treated as a factor. Date Week Time Completed Work_Delta Mean_Delta Balance Total Total_Delta Work Index Open_Bugs Bug_Delta Bug_Delta2 8/17/2009 4 11.8% 64 64 16 611 675 675 9.5% 0.81 333 31 -31 8/30/2009 6 17.6% 104 40 20 801 905 230 11.5% 0.65 269 32 -32
2006 May 02
3
Ajax scaffolding respones are received, but not rendered in browser
Hi i installed the latest ajaxscaffolding gem and generated a scaffold. List works fine. Delete deletes, but the update doesn''t show and the busy icon spins indefinitely. Pressing new or edit also causes the busy icon to spin, but again the ui doesn''t update. my development.log indicates the request was handled and (using firebug) I''m seeing this response: new
2006 May 09
2
Anybody using Macromedia''s Flex with Rails?
Yeah I know this is a bit of a weird question since everybody seems to be going ajax - just curious -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060509/8537fdc3/attachment.html
2006 Mar 18
1
rails-y way to handle quasi-numeric type
I have a class called Duration that represents a unit of time. It has lots of time-related methods and an attribute that represents the duration in seconds. I want to store it in my db. I had a column type of NUMERIC, so if i save it, rails trys to coerce it to a float automagically and fails. I need to display it and store it as a number but treat it in the middle layer as a Duration so I can
2006 Oct 22
2
cross tabs with percents?
-- apologies if this is a dup - i got a bounce saying the message was unprocessed. Is there a straightforward way to get a table with percents in the cells rather than counts? I've looked at table, ftable, xtabs, and ctab, which did the conversion but returned the results in a single row without labels. any suggestions are appreciated. thank you.
2006 Apr 27
2
autocomplete question
I''ve just started using the unbelievably easy and cool auto-complete feature. Does anyone know if you can make it search only from the start of the string (or from the beginning of each word)? By default it seems to do a complete search of the strings - typing MI returns both "Mike Jones" and "Mary Smith". I have to believe this will be much slower as the number of
2006 Aug 05
5
rake migrate error: nil.first
My migrations were working fine until today. I dropped and re-created the database.But, when I go to apply my migrations, rake migrate aborts with this error. You have a nil object when you didn''t expect it! You might have expected an instance of Array. The error occured while evaluating nil.first Any idea what might be wrong? The migrations look right. It''s talking to the