SQL Query To Find And Count Software File And Product Information For A Specified Executable

 

This SQL query will allow you to find and count software file and product information for a specified executable.

 

SQL Query:

 

Select

SF.FileId 'File ID',

SF.ProductId 'Product ID',

SF.FileName 'File Name',

SF.FileDescription 'File Description',

SF.FileSize 'File Size',

SF.FileVersion 'File Version',

SP.ProductName 'Product Name',

SP.ProductVersion 'Product Version',

SP.CompanyName 'Company Name',

Count(SF.FileName) 'Installed Count'

 

From System_DISC SD

Join vSMS_G_System_SoftwareFile SF on SF.ClientId = SD.ItemKey 

Join vSMS_G_System_SoftwareProduct SP on SP.ClientId = SD.ItemKey  

Where SF.ProductId = SP.ProductId

And SF.FileName = 'FileName.Exe'

 

Group by SF.FileId,SF.ProductId,SF.FileName,SF.FileDescription,

SF.FileSize,SF.FileVersion,SP.ProductName,SP.ProductVersion,SP.CompanyName

Order By SF.FileId ASC

 

 

 

 

Published Sunday, March 30, 2008 7:43 AM by dhite
Filed under:

Comments

No Comments