1 of 1 people found this helpful
I believe that the format for the install date is varchar and you can't use the getdate on this type of field. There was a post on this a while back but I can't seem to do a Vulcan Mind Meld with Clearspace right now. THis query will give you scheduled taks installin a date range but will not list software installed out side of LANDesk
DECLARE @start datetime,@finish datetime SET @start = '2008-9-01 12:29:00' SET @finish = '2008-9-30 12:29:00' SELECT LD_TASK.TASK_NAME, LD_TASK_MACHINE.STATUS_TIME, LD_TASK_MACHINE.MAC_RETCODE FROM LD_TASK LD_TASK, LD_TASK_MACHINE LD_TASK_MACHINE WHERE LD_TASK_MACHINE.LD_TASK_IDN = LD_TASK.LD_TASK_IDN AND LD_TASK_MACHINE.MAC_RETCODE <> 1110 AND LD_TASK_MACHINE.MAC_RETCODE <> 1101 AND LD_TASK_MACHINE.MAC_RETCODE <> 1001 AND((LD_TASK_MACHINE.STATUS_TIME Is Not Null And LD_TASK_MACHINE.STATUS_TIME>= @start And LD_TASK_MACHINE.STATUS_TIME<= @finish)) ORDER BY LD_TASK.TASK_NAME
So here is the post. http://community.landesk.com/support/message/16302#16302 Needless to say I ran the query Jack had attached and it does not work. Date ranges where all over the place. Also note that many vendors don't use Install Date.
Install Date is a string, not a Datetime value, so you can't relaibly do date-related arithmetic functions on it... that Dateadd trick is from MS SQL Server and you might be having trouble because of database engine, code page, or who knows what.
This is a problem with the source data rather than LANDesk's handling of it. The vendors are responsbile for updating that field and there is no standard for how it will be formatted.
Your comments, along with Jack Coates are very helpfull and give me the info I needed. Thank you so much.
Thank you Jack, this info is very helpful and has answered my question. Mark