By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
/****** Object: Table [dbo].[assets] ******/
CREATE TABLE [dbo].[assets](
[unid] [int] NOT NULL,
[servername] [nvarchar](50) NOT NULL
) ON [PRIMARY]
/****** Object: Table [dbo].[managers] ******/
CREATE TABLE [dbo].[managers](
[unid] [nvarchar](50) NOT NULL,
[firstname] [nvarchar](50) NULL,
[lastname] [nvarchar](50) NULL
) ON [PRIMARY]
/****** Object: Table [dbo].[properties] ******/
CREATE TABLE [dbo].[properties](
[asset_id] [int] NOT NULL,
[property] [nvarchar](50) NOT NULL,
[property_text] [nvarchar](50) NOT NULL
) ON [PRIMARY]
INSERT [dbo].[assets] ([unid], [servername]) VALUES (1, N'saturn-n1')
INSERT [dbo].[assets] ([unid], [servername]) VALUES (2, N'saturn-n2')
INSERT [dbo].[assets] ([unid], [servername]) VALUES (3, N'mars-n1')
INSERT [dbo].[managers] ([unid], [firstname], [lastname]) VALUES (N'333-111', N'Carl', N'Cox')
INSERT [dbo].[managers] ([unid], [firstname], [lastname]) VALUES (N'333-112', N'David', N'Guetta')
INSERT [dbo].[managers] ([unid], [firstname], [lastname]) VALUES (N'333-113', N'Tim', N'Bergling')
INSERT [dbo].[properties] ([asset_id], [property], [property_text]) VALUES (1, N'manager', N'333-111')
INSERT [dbo].[properties] ([asset_id], [property], [property_text]) VALUES (1, N'stby-manager', N'333-112')
13 rows affected
select * from assets
select * from properties
select * from managers
unid | servername |
---|---|
1 | saturn-n1 |
2 | saturn-n2 |
3 | mars-n1 |
asset_id | property | property_text |
---|---|---|
1 | manager | 333-111 |
1 | stby-manager | 333-112 |
1 | stage | Production |
2 | manager | 333-112 |
2 | stage | Production |
3 | manager | 333-113 |
3 | stby-manager | 333-112 |
unid | firstname | lastname |
---|---|---|
333-111 | Carl | Cox |
333-112 | David | Guetta |
333-113 | Tim | Bergling |