Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 Modify Field DataType in Table using Alter Table

Author  Topic 

Delinda
Constraint Violating Yak Guru

315 Posts

Posted - 2009-11-30 : 12:27:35
I've table structure as follow,

CREATE TABLE tRunno
(
Runn [numeric](15, 0) NOT NULL
)

How to using Alter Table to change my field Runn from numeric into int?

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2009-11-30 : 12:56:43
ALTER TABLE tRunno ALTER COLUMN Runn int NOT NULL

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog

"Let's begin with the premise that everything you've done up until this point is wrong."
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2009-12-01 : 01:53:33
Note that if the table has any value more than 2147483647, you will get arithmetic overflow error

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -