日期:2014-05-18  浏览次数:20637 次

帮忙改写一个sql
在DB2中创建表的语句为:
CREATE TABLE "DBADMIN "."PO_USER_PRINT" (

"ID" INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY (

START WITH +1

INCREMENT BY +1

MINVALUE +1

MAXVALUE +2147483647

NO CYCLE

NO CACHE

NO ORDER ) ,

"USER_CODE" VARCHAR(20) NOT NULL ,

"COMPONENT" VARCHAR(100) NOT NULL )

IN "PO" ;
另外还有一句:
ALTER TABLE "DBADMIN "."PO_USER_PRINT" ALTER COLUMN "ID" RESTART WITH 162;

现在我要把这个在sqlserver2005上创建 要怎么改,请高手帮忙


------解决方案--------------------
CREATE TABLE [PO_USER_PRINT](

ID INT IDENTITY(1,1) ,
USER_CODE VARCHAR(20) NOT NULL , 
COMPONENT VARCHAR(100) NOT NULL