similar to: create_without_callbacks

Displaying 20 results from an estimated 20000 matches similar to: "create_without_callbacks"

2006 Jul 14
1
error with Dates in SQL Server
An application that run without flaw last week has been reported to crash with an error that says that a conversion from char to datetime has given a date outside range. This very application runs OK today in production (fortunately :-), and the difference in both SQL Servers is just that the one where the exception has started to appear has Spanish conventions. I can''t give
2007 Oct 30
1
Merb - Losing connection to MySQL
Hello, Once or twice a day I''m losing connection to MySQL and this error is generated: Mysql::Error: Lost connection to MySQL server during query: INSERT INTO pictures (`content_type`, `name`, `size`, `thumbnail`, `updated_at`, `pictureable_type`, `description`, `pictureable_id`, `filename`, `height`, `user_id`, `parent_id`, `created_at`, `width`) VALUES(''image/jpeg'',
2007 Oct 07
1
How to store a Mechanize object in the database?
Hi, I am trying to save a Mechanize object in database (using a Rails Model). But the save operation throws a TypeError Considering that "agent" is an instance of a Rails Model and "user" is defined as a "text" type in the Model. irb(main):039:0> agent.user = WWW::Mechanize.new #<WWW::Mechanize:0xb71295f0 @follow_meta_refresh=false, @key=nil,
2006 Feb 24
3
Migrations, data loads and changes to the model
Guys, I''ve run across an interesting scenario with my migrations, and I hope you might share some insight. Let''s say I have 3 migrations and two Models (Person and Car): 001_initial_schema.rb 002_data_load.rb 003_add_car_association.rb The first creates the initial schema...the second loads default data using model objects of Person to do so, and the third creates a new
2017 May 17
2
Callback re-registration after libvirtd restart
Hi all, I'm using libvirt-go and I following code to listen for lifecycle events: func event_listen() { log.Printf("event_listen %s", conf.Libvirt.LocalUrl) hv, err := libvirt.NewConnect(conf.Libvirt.LocalUrl) lifecycleCallback := func(c *libvirt.Connect, d *libvirt.Domain, event *libvirt.DomainEventLifecycle) { event_message(c, d, "lifecycle", event)
2008 Jul 27
0
dhtml_calendar Plugin and dates
Man I am frustrated. 4 hours working on this and i can''t find an answer. Here it goes. I had some simple date select fields on a form. Then I wanted to add some additional datetime fields on a form with a nice widget so I installed the dhtml_calendar plugin. Now my migrations and forms don''t work on insert stating that the argument is out of range. Here is line #62 in the
2009 Nov 04
0
The error occurred while evaluating nil.prefetch_primary_key
The error occurred while evaluating nil.prefetch_primary_key? Hi, I have a problem with a model when I have 3 belongs_to relations in one the middle. This example is a subset of a grid-routing project: n 1 1 n +------------ Project Connection ------- ConnectionCost +------------ WaySearchRun
2012 Jan 17
3
Saving without callbacks in Rails 3
Hi all, Saving without callbacks is not working in rails 3.1. please tell me alternatives available...... Thanks, Kingston -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to
2008 Oct 28
7
aasm callback order?
Hello! Sometime ago I ran across a webpage where someone had identified the full callback sequence for an object lifecycle including AASM with it''s :enter and :exit and whatnot callbacks. Unfortunately, I can''t find it and searches don''t seem to help. Does anyone have a reference to a page that shows the callback sequence with Acts As State Machine (the gem)? I think
2006 Nov 04
0
ActiveRecord, insert and not auto-incremented primary keys...
Hi, After playing while with ActiveRecord, I''m surprised it isn''t easier to insert data into a table whose primary key is not auto-incremented by the database server. The following code... --------------------------------------- -- MySQL database "test" --------------------------------------- CREATE TABLE gardens ( code integer NOT NULL, name
2008 Dec 20
9
Upgrade to Rails 2 - problem with "save" (MySQL boolean issue?)
I have been working through an upgrade of my 1.2.6 application to 2.2.2. I am almost there but I have hit a problem with ActiveRecord. Before the upgrade, the following code was working fine. def create_root(administrator) root = create_root_collection(self.pingee_name, administrator,
2007 Oct 07
10
Rails to English
I am currently using the book "Agile Web Development With Rails" (2005). I am working on a fully function web application that has a shopping cart. The web page displays this, ActiveRecord::StatementInvalid in AdminController#create Mysql::Error: #23000Column ''date_available'' cannot be null: INSERT INTO products (`image_url`, `date_available`, `price`, `title`,
2005 Dec 16
0
ArgumentError on create
I have several validations applied to my model: class Quote < ActiveRecord::Base has_many :files validates_presence_of :title, :source, :quote, :message => "Missing Field Required" validates_length_of :title, :source, :maximum => 80, :message => "Maximum Length 80 characters" validates_inclusion_of :year, :in=>1911..2006, :message => "Year must be
2006 Mar 16
10
Nubee Callbacks problem
I never want to alter a model(row). When a model has been changed i want a new copy to be created. What is the best way to implement this? I think using callbacks might be the answer. So model.save will create a new row, and leave the old one unchanged. Any ideas? I can easily implement this in the controller but i''d rather it be done transparently. Also errors should be passed back
2009 Sep 30
3
SQLite3::SQLException: id may not be null
I am getting the following error using sqlite3. If I ran the same query directly in sqlite3 client, the data is saved without error. Same is happening for every table during inserts. SQLite3::SQLException: sessions.id may not be NULL: INSERT INTO sessions ("updated_at", "session_id", "data") VALUES(''2009-09-30 02:28:45'',
2006 Apr 08
6
Deploy with Capistrano Win32 -> Linux
Im trying to deploy with capistrano from win32 to Linux but no success. I''ve been installed: cwRsync to ssh I ran rake remote:exec ACTION=setup --trace and get: Anyone knows how to get capistrano log ssh comunication? Any idea? Thanks rake aborted! End of file reached c:/ruby/lib/ruby/gems/1.8/gems/net-ssh-1.0.8/lib/net/ssh/transport/version-negot iator.rb:51:in `readline''
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 Mar 28
4
Problem with ActiveRecord, create, save, and Oracle adapter?
Hi all, Ruby 1.8.4 Rails 1.1 OCI8 0.1.14 I think I''m hitting an issue with ActiveRecord::Base#save and the Oracle adapter. Line 158 in the schedules_controller.rb file is simply: 158: if @schedule.save 159: flash[:notice] = ''Schedule was successfully created.'' 160: redirect_to :action => ''list'' 161: else 162: render :action =>
2006 Aug 08
1
File upload into Mysql (using lighttpd) problem
Hello All, I''ve run into a snag. (I apologize in advance. I''m not very good at system administration.) I''m building an app that allows users to upload files. Up until now I have been storing the files on the file system, but tonight I decided to change the app so the files are stored in the database as a longblob. I thought everything was working great, until I
2009 Dec 03
1
Ann: ArEvents
Hi, I needed to be able to add actions to be taken during the lifecycle of ActiveRecord object, but needed to configure it dynamically. Observers were not flexible enough and I ended up developing ArEvents, which lets you easily attach and detach event listeners, the events correspond to the active record callbacks. If you have an existing model, just include the ArEvents module: