Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3279746
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:37:38+00:00 2026-05-17T19:37:38+00:00

I noticed that my application was automatically setting all my processes to having been

  • 0

I noticed that my application was automatically setting all my processes to having been completed as soon as they were created. I looked through it, couldn’t find why the date was being updated without being told to, but I found that one of my views was looking for a field that didn’t exist. I created the ‘complete’ field, set it as a not null boolean and tried again.

I was getting it being set automatically to true again so I tried setting it as false explicitly in the create method, this still didn’t work :S so I tried putting a hidden field into the form. I am now getting a “column cannot be null” error even though the value is being provided.

As you can see there is clearly a parameter for the complete value. What am I missing?

Error:

Mysql::Error: Column 'complete' cannot be null: INSERT INTO `decommissions` (`completed_at`, `keep_backups`, `services_stopped`, `updated_at`, `operating_system_id`, `comments`, `username`, `disposition`, `stakeholder_email`, `complete`, `alias`, `storage`, `model_id`, `contract_maintenance`, `created_at`) VALUES(NULL, 1, 1, '2010-10-18 00:32:37', 1, NULL, NULL, '', 'test@qut.edu.au', NULL, 'test1', '', 1, '', '2010-10-18 00:32:37')

Parameters:

{"decommission"=>{"dns_items_attributes"=>{"0"=>{"ip"=>"131.181.185.111",
 "alias"=>"test",
 "retain"=>"1",
 "_destroy"=>""}},
 "keep_backups"=>"1",
 "services_stopped"=>"1",
 "operating_system_id"=>"1",
 "stakeholder_email"=>"test@qut.edu.au",
 "alias"=>"test1",
 "model_id"=>"1"},
 "commit"=>"Submit",
 "authenticity_token"=>"cMMf0zS/5jPExlXqVPaYVXndqPeVkm+OQ/WEPIYd2+g=",
 "disposition"=>"Dispose",
 "complete"=>"false",
 "storage"=>"Local",
 "contract_maintenance"=>"0"}

When I put the following in my create controller it renders ‘true’:

@decommission = Decommission.new(params[:decommission])
@decommission.complete = false
render :text => @decommission.complete
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T19:37:39+00:00Added an answer on May 17, 2026 at 7:37 pm

    @zetetic

    I did have a method called complete, I renamed this but the problem was still occurring.

    The problem occurred for all the following values:
    “disposition”=>”Dispose”,
    “complete”=>”false”,
    “storage”=>”Local”,
    “contract_maintenance”=>”0”

    These values were received using normal form selectors rather than rails ones. That was the only thing I could find that they had in common. I ended up running some experimental tests and found that the values were not being stored withing the decommission object, but rather in their own.

    So in the controller I ran a few extra lines to set the values within the decommission object to equal the parameters associated with it:

    @decommission.storage = params[:storage]
    @decommission.contract_maintenance = params[:contract_maintenance]
    @decommission.disposition = params[:disposition]
    @decommission.complete = false
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been working on a DirectX application in C#, and I noticed that when
I've noticed that you can manually recycle an application pool via IIS and that
I'm developing a Flex 2 application, and I noticed that part of the library
We distribute an application that uses an MS Access .mdb file. Somebody has noticed
Recently I noticed my application appears to be eating memory that never gets released.
I am writing a C# application that, among other things, automatically closes the advertisement
I have a view in my Django application that automatically creates an image using
As a two-monitor user at work, I've noticed that applications behave differently with regards
I've noticed that a handful of WCF applications choose to break their objects apart;
i've noticed that plenty of games / applications (very common on mobile builds) pack

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.