cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Okan
Engaged Sweeper III
I converted a server from physical to virtual. When Lansweeper scanned it again, it new that it was a VMWare image, but it also kept the warranty information. Since it is virtual now, I would like to get rid of the warranty information for the virtual server. How can I do that other than deleting it in the database?
1 ACCEPTED SOLUTION
Jeremy_D
Champion Sweeper
If Lansweeper finds an asset's warranty details today, but not tomorrow, it will indeed keep displaying the warranty information scanned today. The purchase and warranty dates can easily be cleared manually, by hitting the Edit Asset button on the asset page. To remove the actual warranty products though, you'll need to delete the records directly in the database, as you indicated as well.

The following database tables are used to store warranty information: tblWarranty and tblWarrantyDetails. I included a sample script below that deletes the warranty products of computer LAN-010 in domain Lansweeper. You can insert your own values into the script. We do recommend backing up your database prior to running any potentially dangerous statements such as DELETE FROM or TRUNCATE TABLE. Backup instructions are available in this knowledge base article.
delete from tblwarrantydetails where warrantydetailsId In (Select Top 1000000 tblWarrantyDetails.WarrantyDetailsId
From tblAssets
Inner Join tblWarranty On tblAssets.AssetID = tblWarranty.AssetId
Inner Join tblWarrantyDetails On tblWarranty.WarrantyId =
tblWarrantyDetails.WarrantyId
Where tblAssets.AssetName = 'lan-010' And tblAssets.Domain = 'lansweeper')

View solution in original post

2 REPLIES 2
Okan
Engaged Sweeper III
Thank you Jeremy. This fixed my question. I wanted to make sure I did not miss anything before doing it in the db.
Jeremy_D
Champion Sweeper
If Lansweeper finds an asset's warranty details today, but not tomorrow, it will indeed keep displaying the warranty information scanned today. The purchase and warranty dates can easily be cleared manually, by hitting the Edit Asset button on the asset page. To remove the actual warranty products though, you'll need to delete the records directly in the database, as you indicated as well.

The following database tables are used to store warranty information: tblWarranty and tblWarrantyDetails. I included a sample script below that deletes the warranty products of computer LAN-010 in domain Lansweeper. You can insert your own values into the script. We do recommend backing up your database prior to running any potentially dangerous statements such as DELETE FROM or TRUNCATE TABLE. Backup instructions are available in this knowledge base article.
delete from tblwarrantydetails where warrantydetailsId In (Select Top 1000000 tblWarrantyDetails.WarrantyDetailsId
From tblAssets
Inner Join tblWarranty On tblAssets.AssetID = tblWarranty.AssetId
Inner Join tblWarrantyDetails On tblWarranty.WarrantyId =
tblWarrantyDetails.WarrantyId
Where tblAssets.AssetName = 'lan-010' And tblAssets.Domain = 'lansweeper')