Skip to main content
Post Closed as "Duplicate" by Paul White, Aaron Bertrand
edited tags
Link
Paul White
  • 90.3k
  • 30
  • 424
  • 663
tagged sql-server. Formatted error
Source Link
Mark Sinkinson
  • 10.6k
  • 4
  • 46
  • 54

I have a existing table in which i am adding a column as NgoId whose datatype is int. I want to add as NOT NULL to the column .

When I mI'm adding this I am getting the following error as:

  • Unable to modify table.
    Cannot insert the value NULL into column 'NgoId', table 'CSR.dbo.Tmp_tbl_post_category'; column does not allow nulls. INSERT fails. The statement has been terminated.

Unable to modify table. Cannot insert the value NULL into column 'NgoId', table 'CSR.dbo.Tmp_tbl_post_category'; column does not allow nulls. INSERT fails. The statement has been terminated.

Please help how to add the column with NOT NULL.

I have a existing table in which i am adding a column as NgoId whose datatype is int. I want to add as NOT NULL to the column .

When I m adding this I am getting error as

  • Unable to modify table.
    Cannot insert the value NULL into column 'NgoId', table 'CSR.dbo.Tmp_tbl_post_category'; column does not allow nulls. INSERT fails. The statement has been terminated.

Please help how to add the column with NOT NULL.

I have a existing table in which i am adding a column as NgoId whose datatype is int. I want to add as NOT NULL to the column .

When I'm adding this I am getting the following error:

Unable to modify table. Cannot insert the value NULL into column 'NgoId', table 'CSR.dbo.Tmp_tbl_post_category'; column does not allow nulls. INSERT fails. The statement has been terminated.

Please help how to add the column with NOT NULL.

Source Link
hud
  • 203
  • 2
  • 6
  • 21

Add a column with Not Null

I have a existing table in which i am adding a column as NgoId whose datatype is int. I want to add as NOT NULL to the column .

When I m adding this I am getting error as

  • Unable to modify table.
    Cannot insert the value NULL into column 'NgoId', table 'CSR.dbo.Tmp_tbl_post_category'; column does not allow nulls. INSERT fails. The statement has been terminated.

Please help how to add the column with NOT NULL.