Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X
Hi.
I newbie in SQL.
I created sequence as described in "Persistence Datastore Sequence Customization" chapter of customization guide:
CREATE TABLE wt_sequence_<MySequence> (dummy CHAR(1),
value BIGINT IDENTITY(<MySequenceSeed>,<MySequenceIncrement>))
go
CREATE PROCEDURE wt_get_next_sequence_<MySequence> @returnValue BIGINT OUTPUT
AS
INSERT wt_sequence_<MySequence> (dummy) VALUES ('x')
SELECT @returnValue = SCOPE_IDENTITY()
go
For testing period i set MySequenceSeed = 1.
How can i later change MySequenceSeed ?
Thanks.
Solved! Go to Solution.
Next code changes sequence start = 20:
SET IDENTITY_INSERT wt_sequence_<MySequence> ON;
GO
INSERT wt_sequence_<MySequence> (dummy, value) VALUES ('x', 19)
Next code changes sequence start = 20:
SET IDENTITY_INSERT wt_sequence_<MySequence> ON;
GO
INSERT wt_sequence_<MySequence> (dummy, value) VALUES ('x', 19)