Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- create one identity
- exec kST_Stage 1
- -- insert one row, should succeed
- insert into ST_NAM_Stage_Name values
- (1, 'Alpha', '2001-01-01', '2012-01-01', '9999-12-31');
- -- insert "same" row, should fail due to primary key constraint
- insert into ST_NAM_Stage_Name values
- (1, 'Alpha', '2001-01-01', '2012-01-01', '9999-12-31');
- -- insert overlapping row, should fail due to overlapping constraint
- insert into ST_NAM_Stage_Name values
- (1, 'Alpha', '2001-01-01', '2012-01-01', '2012-02-02');
- -- insert negative interval, should fail due to interval constraint
- insert into ST_NAM_Stage_Name values
- (1, 'Omega', '2001-01-02', '2012-01-01', '2001-01-01');
- -- insert temporal duplicate, should fail due to uniqueness constraint
- insert into ST_NAM_Stage_Name values
- (1, 'Omega', '2001-01-01', '2013-01-01', '9999-12-31');
- -- insert changed value, should succeed
- insert into ST_NAM_Stage_Name values
- (1, 'Omega', '9999-12-31', '2012-01-01', '9999-12-31');
- -- looking at some values
- select * from ST_NAM_Stage_Name
- select * from lST_Stage
- select * from pST_Stage('2012-01-02')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement