SEQUENCE OBJECT


IF ( EXISTS ( SELECT    *
              FROM      sys.sequences
              WHERE     name = 'SequenceObj5' ) )
    BEGIN
        DROP SEQUENCE SequenceObj5;
    END;
GO

CREATE SEQUENCE SequenceObj5
AS INT
START WITH 14--設定起始值
INCREMENT BY 1 --設定每次增加/減少多少
MINVALUE 10--設定最小值(選填)
MAXVALUE 15--設定最大值(選填)
CYCLE --重複循環(選填)
CACHE 10;

results matching ""

    No results matching ""