Workflow.Task

Type

Read/write

Author

Availability

Data provider

Read

FINBOURNE

Provided with LUSID

Providing you have sufficient access control permissions, the Workflow.Task provider enables you to write a Luminesce SQL query that retrieves tasks from the Workflow Service.

See also: Workflow.Task.Writer, Workflow.Task.Field, Workflow.TaskDefinition

Basic usage

select * from Workflow.Task where <filter-expression>

Query parameters

Workflow.Task has parameters that enable you to filter or refine a query.

To list available parameters, their data types, default values, and an explanation for each, run the following query using a suitable tool:

select FieldName, DataType, ParamDefaultValue, Description from Sys.Field where TableName = 'Workflow.Task' and FieldType = 'Parameter';

Data fields

By default, Workflow.Task returns a table of data populated with particular fields (columns). You can return a subset of these fields.

To list fields available to return, their data types, whether fields are considered 'main', and an explanation for each, run the following query using a suitable tool:

select FieldName, DataType, IsMain, IsPrimaryKey, SampleValues, Description from Sys.Field where TableName = 'Workflow.Task' and FieldType = 'Column';

Note: Fields marked 'main' are returned by queries that select a caret character, for example select ^ from Workflow.Task.

Examples

Note: For more example Luminesce SQL queries, visit our Github repo.

Example 1: Retrieve first 10 tasks

select * from Workflow.Task limit 10;

Example 2: Retrieve the current state of a particular task

select State from Workflow.Task where Id = '22ffcc7c-3ab6-48cd-9c31-1c702b04a95e';

Example 3: Retrieve all child tasks for a particular parent task

select * from Workflow.Task where ParentId = '22ffcc7c-3ab6-48cd-9c31-1c702b04a95e' or UltimateParentId = '22ffcc7c-3ab6-48cd-9c31-1c702b04a95e';