How to Drop a Column in SQL Server

Last updated July 25, 2026 · By the SaturnSQL team

Use ALTER TABLE ... DROP COLUMN. It fails if any constraint or index depends on the column, most often a DEFAULT constraint, which you must drop by name first.

ALTER TABLE orders DROP COLUMN internal_notes;

Drop the default constraint first

A column with a DEFAULT fails with 'The object DF_... is dependent on column ...'. Find the constraint name, drop it, then drop the column.

SELECT dc.name
FROM sys.default_constraints dc
JOIN sys.columns c
  ON c.object_id = dc.parent_object_id
 AND c.column_id = dc.parent_column_id
WHERE dc.parent_object_id = OBJECT_ID('orders')
  AND c.name = 'discount';

ALTER TABLE orders DROP CONSTRAINT DF_orders_discount;
ALTER TABLE orders DROP COLUMN discount;

Run this in SaturnSQL

SaturnSQL is a browser-based SQL editor for teams: shared query library, schema-aware autocomplete, and scheduled exports to Google Sheets and Slack.

Try it free

Related SQL Server guides

© 2026 Panda Capital Oy Ab. All rights reserved.