USE [Configuration02_Def]
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=1)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (1, 1, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=2)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (2, 1, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=3)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (3, 1, 32, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=4)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (4, 1, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=5)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (5, 1, 128, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=6)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (6, 1, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=7)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (7, 1, 3, 3)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=8)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (8, 1, 4, 3)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=9)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (9, 2, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=10)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (10, 2, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=11)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (11, 2, 32, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=12)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (12, 2, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=13)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (13, 2, 128, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=14)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (14, 2, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=15)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (15, 2, 3, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=16)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (16, 2, 4, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=17)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (17, 3, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=18)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (18, 3, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=19)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (19, 3, 32, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=20)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (20, 3, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=21)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (21, 3, 128, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=22)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (22, 3, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=23)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (23, 3, 3, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=24)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (24, 3, 4, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=33)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (33, 5, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=34)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (34, 5, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=35)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (35, 5, 32, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=36)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (36, 5, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=37)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (37, 5, 128, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=38)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (38, 5, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=39)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (39, 5, 3, 3)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=40)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (40, 5, 4, 3)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=41)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (41, 6, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=42)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (42, 6, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=43)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (43, 6, 32, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=44)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (44, 6, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=45)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (45, 6, 128, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=46)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (46, 6, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=47)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (47, 6, 3, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=48)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (48, 6, 4, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=49)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (49, 7, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=50)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (50, 7, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=51)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (51, 7, 32, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=52)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (52, 7, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=53)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (53, 7, 128, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=54)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (54, 7, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=55)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (55, 7, 3, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=56)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (56, 7, 4, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=57)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (57, 8, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=58)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (58, 8, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=59)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (59, 8, 32, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=60)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (60, 8, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=61)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (61, 8, 128, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=62)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (62, 8, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=63)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (63, 8, 3, 3)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=64)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (64, 8, 4, 3)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=65)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (65, 9, 1, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=66)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (66, 9, 2, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=67)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (67, 9, 32, 5)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=68)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (68, 9, 64, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=69)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (69, 9, 128, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=70)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (70, 9, 256, 6)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=71)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (71, 9, 3, 4)
GO

IF NOT EXISTS(SELECT * FROM [dbo].[tblUIElement_Rule] WHERE nID=72)
	INSERT [dbo].[tblUIElement_Rule] ([nID], [nRuleID], [nElementID], [nAttributeID]) VALUES (72, 9, 4, 4)
GO



