If the procedure already exists and you need to change it then you may need to use ALTER instead of CREATE:
ALTER PROCEDURE dbo.precetics AS SELECT * FROM Department where id=1 GO
Note: From SQL Server 2016 you can do
CREATE OR ALTER PROCEDURE dbo.precetics AS SELECT * FROM Department where id=1 GO
which will always work without erroring regardless the procedure exists or not. In previous SQL server you can go around the issue by testing for existence first.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…