# Related Sites > SQL Course >  what is wrong with my tables

## sql

Hi all: I run this table an got error

Column or parameter #4: Cannot specify a column width on data type int.
why??
/* test for existence of table; drop it if exists */
if exists 
	(select * from sysobjects where id = object_id(N'[Categories]') 
		and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [Categories]
GO
/* This table depends on SITES */

CREATE TABLE Categories
(
	CategoryID		int IDENTITY(1,1) NOT NULL PRIMARY KEY CLUSTERED,
	SiteID			int FOREIGN KEY (SiteID) REFERENCES Sites(SiteID),
	CategoryName		VarChar(50) NOT NULL,
		/* Make sure that the sort order is a number 1 - 99. But we can still order
		by Alphabetical in code */
	DefaultSortOrder	int(2) NOT NULL CONSTRAINT CK_DefaultSortOrder CHECK 
					(DefaultSortOrder LIKE '[1-9]' OR
					DefaultSortOrder LIKE '[1-9][0-9]')
)
GO
________
Hawaii Dispensaries

----------


## skhanal

You are declaring defaultsortorder as int(2), use int only.

----------


## YuckFou

remove (2) in
...DefaultSortOrder int(2) NOT ...

...*DefaultSortOrder int NOT* ...

----------

