declare @Virtualname varchar(255)
declare @Virtual varchar(255)
create table #OSinfo(OSinfo varchar (255))
insert into #OSinfo
exec master..xp_cmdshell 'systeminfo'
set @Virtualname =(select ltrim(SUBSTRING(OSinfo,CHARINDEX(' ',OSinfo),LEN(OSinfo)))
from #OSinfo
where OSinfo like '%system%' and OSinfo like '%manufacture%')
if (@Virtualname not like...