Code: Select all
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[rapid7core]') AND type in (N'U'))
DROP TABLE [dbo].[rapid7core]
GO
/****** Object: Table [dbo].[rapid7core] Script Date: 8/1/2022 11:12:48 AM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[rapid7core](
[hostname] [varchar](128) NOT NULL,
[machine_domain] [varchar](128) NULL,
[external_ip] [varchar](128) NULL,
[hrb_status_active] [bit] NULL,
[bios_manufacturer] [varchar](64) NULL,
[bios_version] [varchar](64) NULL,
[product_type_desc] [varchar](128) NULL,
[serial_number] [varchar](64) NOT NULL,
[system_manufacturer] [varchar](64) NULL,
[system_product_name] [varchar](64) NULL,
[modified_timestamp] [datetime] NULL,
[first_seen_create_date] [timestamp] NULL,
[last_seen] [datetime] NULL,
[agent_local_time] [datetime] NULL,
[mac_address] [varchar](64) NULL,
[local_ip] [varchar](64) NULL,
[device_id] [varchar](64) NULL,
[cid] [varchar](64) NULL,
[agent_version] [varchar](64) NULL,
[ou] [varchar](256) NULL,
[os_version] [varchar](64) NULL,
[os_build] [varchar](64) NULL,
[platform_name] [varchar](64) NULL,
[reduced_functionality_mode] [varchar](64) NULL,
[device_policies] [varchar](256) NULL,
[groups] [varchar](256) NULL,
[site_name] [varchar](128) NULL,
[classid] [varchar](64) NULL,
[last_update] [datetime] NULL,
[last_update_by] [varchar](64) NULL,
[instanceid] AS ('DIPS-'+CONVERT([varchar](36),newid()))
) ON [PRIMARY]
GO