Archive report
I am trying to create a custom report that will show me all items that are archived. I don't see any option that allows me to do this. I don't know sql, so I am using the wizard. In addition, is it possible to set assets that have been archived to fall off after a certain amount of time? Thanks!
3 Comments
[ + ] Show comments
-
All archived assets, regardless of asset type? What details should be included? - chucksteel 6 years ago
-
All archived assets, but it would be nice to be able to select the type of asset and a date range. - tgrinnell 6 years ago
-
Date range for what? When the asset was archived? - chucksteel 6 years ago
-
Yes, for when the asset is archived. - tgrinnell 6 years ago
-
Thank you! I will give it a try. - tgrinnell 6 years ago
Answers (1)
Please log in to answer
Posted by:
chucksteel
6 years ago
This should work for you:
SELECT ASSET.ID,
ASSET_TYPE.NAME as "Asset Type",
ASSET.NAME,
ASSET.MODIFIED,
ASSET.CREATED,
ASSET.ARCHIVE_DATE,
ASSET.ARCHIVE_REASON
FROM ORG1.ASSET
LEFT JOIN ASSET_TYPE on ASSET_TYPE.ID = ASSET.ASSET_TYPE_ID
WHERE ARCHIVE = "COMPLETED"
AND ASSET_TYPE.NAME = "Computer"
AND DATE(ARCHIVE_DATE) BETWEEN "2017-07-19" AND "2018-04-30"
If you don't want to use the options for asset type or archived date, then just remove those lines.