KBA-01475: SQL Report Parameters

Summary:

In order to provide a consistent user experience, Spitfire recognizes certain report parameter names and uses standard user interface methodology to prompt the user. These parameter names include:

  • pProject – uses free from text input and is intended for use with a SQL LIKE clause.  Special handling is provided for the ‘default‘ values
    • Required! – Spitfire will replace the value with either the most recently tracked project (My Settings) or a percent sign (%) and wait for the user to review parameters before gathering data.
    • Required^ – (v2019) Spitfire will replace the value with a percent sign (%) and wait for the user to review parameters before gathering data.
  • pResponsible – uses Validated Text with lookup on FullContactList.  The report parameter is set to the GUID of the chosen contact.
  • pCurrentUser – is always set to the GUID of the currently logged-in Spitfire user. The parameter is hidden from the user and cannot be changed. This allows reports to know the identity of the user and determine access permissions to potential report data.
  • pSubcontractor – uses Validated Text with label ‘Subcontractor‘ and lookup on SubcontractorList. The report parameter is set to the GUID of the chosen contact.
  • pScope – uses a DropDown, listing the values from SetName=‘ContactScope‘.  Normally used in combination with pCompany and/or pContact.
  • pCompany – uses Validated Text with lookup on PrimaryCompanyContacts.  The report parameter is set to the GUID of the chosen contact.
  • pContact – uses Validated Text with lookup on FullContactList. The report parameter is set to the GUID of the chosen contact.
  • pUserKey – uses Validated Text with lookup on FullContactList.  The report parameter is set to the GUID of the chosen contact.
  • pSubmittalCompany – uses Validated Text with label ‘Submittal Contact‘ and lookup on FullContactList.  The report parameter is set to the GUID of the chosen contact.
  • pPackageCompany – uses Validated Text with label ‘Package Contact‘ and lookup on FullContactList.  The report parameter is set to the GUID of the chosen contact.
  • pOrganizationDiv – uses Validated Text with label ‘Company/Division‘ and lookup on CompanyLookup.
  • pSubcontractLookup – uses Validated Text with label ‘Subcontract‘ and lookup on Subcontracts given a project.
  • pCustomer – uses Validated Text with label ‘Customer‘ and lookup on CustomerList. The report parameter is set to the GUID of the chosen contact.
  • pManager – uses Validated Text with label ‘PM Name‘ and lookup on UserEmployeeContact. The report parameter is set to the GUID of the chosen contact.
  • pItem – uses Validated Text with label ‘File‘ and lookup on CatalogFile. The report parameter is set to the GUID of the chosen file.
  • pFolderKey – uses Validated Text with label ‘Folder‘ and lookup on CatalogFolder. The report parameter is set to the GUID of the chosen folder.
  • pUser – uses Validated Text with label ‘User‘ and lookup on UserContactList. The report parameter is set to the GUID of the chosen contact.
  • pDocument – uses Validated Text with label ‘Document Key‘ and lookup on DocumentList.  The report parameter is set to the GUID of the chosen document.

Date Parameters

Date parameters must begin with one of three prefixes.  Note: do not include the @ that is required by the SQL-side query parameter!

  • pD
  • pF
  • pT

Special handling is provided for PAIRS of date parameters such as pfXYZ and ptXYZ.  This pair must occur in that order (pf, then pt).  The pair is replaced by a single date range UI in Spitfire with a label based on pfXYZ with (from) removed.

Additional Comments:

The list of enhanced report filters above can be extended or modified using FilterItem entries in SiteConfig.XML.  See KBA-01279 and contact your implementer.


KBA-01475; Last updated: August 27, 2019 at 21:27 pm;
Keywords:  SSRS; reports