Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • CodeMaster2008 151 posts 184 karma points
    May 03, 2010 @ 19:41

    Cannot insert the value NULL into column 'Created', table 'mydb.dbo.UFRecords'; column does not allow nulls

    This is the error i get when i click on the submit button of all my forms.
    Here is the scenario:

    Before upload my portal, i installed Contour on my local machine and created 3 forms.
    I tested the forms with the trial version and it appears to be working.

    I uploaded everything to the server and used the "Export Data" function on Management Studio 2008 to connect to the remote database and transfer the database objects and data.

    The portal loaded just fine. Everything on it's place. After that i went to the countour and registered it.
    Finally i tried the form and got this error message.

    I went to the database and the tables are there, also, as it says,the 'Created' and 'Updated' fields wont allow null values.

    Does anybody know how to fix it?
    Thanks in advance.

  • CodeMaster2008 151 posts 184 karma points
    May 04, 2010 @ 15:37

    For some reason the problem was caused during the export process.
    I scripted the database instead, executed the scritp on the remote database and it's now working.

  • Thomas Kahn 602 posts 506 karma points
    May 24, 2010 @ 09:59
    Thomas Kahn

    I'm experiencing the exact same problem and I've also copied the database using the "Export Data" function in Management Studio 2008. So I try to script the database using Visual Studio 2008 instead. This fails and I get the error:

    Property Text is not available for DefaultConstraint '[DF_cmsContentType_thumbnail]'. This property may not exist for this object, or may not be retrievable due to insufficient access rights.

    Could this have something to do with the fact that I'm using FamFamFam icons in Umbraco?


  • Thomas Kahn 602 posts 506 karma points
    May 24, 2010 @ 11:06
    Thomas Kahn

    Just in case anybody stumbles accross the above error, it occurs if you forget to assign the role "db_owner" to the user that you are logging in with when you are scripting the database in Visual Studio. As soon as the user is "db_owner", it works!

    I can also confirm that exporting the data doesn't work, but if you script the database it works.

  • Per Ploug 865 posts 3491 karma points MVP admin
    May 24, 2010 @ 12:02
    Per Ploug

    The issue is with the Export tables functionality in Sql management studio, as it doesn't do anything by exporting the tables. 

    Default values, keys, constraints, etc etc, are not included.

    We use the Sql Wizard usually to generate scripts with instead:


  • Lincoln Vu 8 posts 29 karma points
    Jun 13, 2012 @ 21:06
    Lincoln Vu

    I followed Codemaster2008 and was able to get my umbraco working. Thanks.
    For how to script the DB, I followed this 

  • Mike Cooper 10 posts 50 karma points
    Nov 06, 2012 @ 22:57
    Mike Cooper

    I had the same problem migrating structure and data correctly from SQL Management Studio.
    But Lincoln Vu's link worked well to resolve my issue as well. Thanks!

    Visual Studio > Data Connections > [db] > Publish to Provider....

  • denisedelbando 141 posts 339 karma points
    Aug 17, 2017 @ 15:25

    i know this is late. but scripting works for me.

    Just dont forget when you script to include the indexes. by default it is not included

Please Sign in or register to post replies

Write your reply to: