tawalsh3
asked on
Delete a Column in SQL Server 2000
I am trying to write SQL code to delete a column in MS SQL Server 2000 via the SQL Query Analyzer. For example, the following code adds a column to a table:
ALTER TABLE dbo.t_Auto
ADD BIRTH_DATE datetime null
How would I write a query to delete this field. I thought it should look like this:
ALTER TABLE dbo.t_Auto
DELETE BIRTH_DATE datetime null
But I am getting a syntax error. Also tried:
ALTER TABLE dbo.t_Auto
DROP BIRTH_DATE datetime null
Same syntax error. I know this is an easy question. Help!
ALTER TABLE dbo.t_Auto
ADD BIRTH_DATE datetime null
How would I write a query to delete this field. I thought it should look like this:
ALTER TABLE dbo.t_Auto
DELETE BIRTH_DATE datetime null
But I am getting a syntax error. Also tried:
ALTER TABLE dbo.t_Auto
DROP BIRTH_DATE datetime null
Same syntax error. I know this is an easy question. Help!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.