Navigating the Data
Note:This SafetyChain Power BI Connector documentation assumes users have an advanced level of experience using Power BI and therefore may not cover general Power BI desktop or web functionality.
Summary
The SafetyChain Power BI Connector provides you with a list of functions to generate tables which can then be used to transform your data through Power Query. Once you successfully connect and load your functions you can view them in your Power Query Editor (Transform Data).
Note:When the window opens, if the queries display an error indicator that says "Authentication.Error: Unauthorized” in the Transform Data window, it may be necessary to refresh the preview. To do so, select the Refresh Previews button and choose the appropriate option to refresh one or all queries. If your credentials are correct, this will resolve the error.
GetForms Example
Enter the parameters as listed
Click Invoke and the data will appear.
Rename the function accordingly for use within the Power BI Framework.
Function Parameters
NoteQuery performance depends on the volume of data retrieved within the selected time frame. Using Submitted Date Types and narrower date ranges can improve performance, but may exclude relevant data. Choose your date range carefully to balance speed and completeness.
All the functions use parameters to query and filter the data from SafetyChain. The parameters are defined below:
Parameter Name | Type | Description | Functions Used |
|---|---|---|---|
| text | Will be used with the date filters Start Date and End Date or Minutes Ago. -**SubmittedDate **is the records date/time when it was submitted. This may be different then the date a record is processed. For example, submitting a record in Mobile that is offline and then processed at a later time when the device has connectivity.
| GetForms |
Time Zone Offset | number | Used with the date filters Start Date and End Date or Minutes Ago to adjust time according to the time zone you are querying. In addition the Submitted, Processed and Modified dates will be provided in the provided TimeZone. e.g. 0 will return times in UTC. The offset should be in Hours. Example -6, -7, -8 for EST, CST, and PST. | GetForms |
Start Date* | date/time | Must be used with End Date to create a date range query. | GetForms |
End Date* | date/time | Must be used with Start Date to create a date range query. | GetForms |
Minutes Ago* | number | Used as sliding time scale to query from now to # of minutes ago. e.g. 1440 would be querying record data from 24 hours ago to now. | GetForms |
Form Name | text | If left blank there would be no filter applied and must be used with Form Query Type | GetForms |
| text | Used with Form Name to filter on FormName(exact match to the form name) or FormLike(uses a contains query on form name) | GetForms |
| text | Provides Field Values or Field Details and the results will format the table in a flat or vertical view. Field Details will be used to get all spec values, corrections, comments and field values. Field Values will provide the table with one row per record and field short name as each column and the value in each cell. | GetRecordFields |
Verification Name | text | Used to filter verifications related to all records. This is an exact match filter, which will provide all records and their related verifications per each record. There can be more than one row per record as there can be multiple verifications per record. | GetVerifications |
| text | Used to filter on resource type with the Resource Name. If using Resource Name, please make sure that name corresponds with the correct resource type. Resource Name can be left blank to get all resources based on the type. | GetResourceDetails |
Tree Like | text | Used as a contains filter on category and resource name e.g. Items > Ice Cream > Finished Product > Round line - BE > 170571-67015A - TMK Oregon Stwbry Ic 6/1.75 Qt - BE | GetResourceDetails |
Resource Name | text | Used to filter on exact Resource Name. Can provide a blank value ("") to get all resources. GetFormsByResource this field is required. | GetResourceAttributes |
Request Identifier Should only be used when necessary. | text/alpha numeric (10 digits) | (Optional) Use this parameter when a function may be invoked concurrently by multiple simultaneous calls. Most functions begin by establishing a temporary "cache" table — named using the function name and User ID — that holds filtered record data to be joined with other data for the final output. Adding a RequestIdentifier appends its value to the cache table name, ensuring each concurrent call references a unique table and preventing conflicts. | GetForms |
Updated about 1 month ago
Let's look in more detail on using some of the functions

