Skip to main content

Hi guys,

I would like to ask if anyone knows a way to find out wether a user has a long-term task delegation set. And I need to do this from inside of my workflow.

I know the Nintex Webservice offers Methods for setting and deleting such a delegation rule but I haven't found a way to just get a true/false if a certain user has a delegation rule set for a certain time.

Any help is highly appreciated!

Regards
Philipp

You can use an "Execute SQL" action to get the long term task delegations for a particular user as the databasetable "Delegation" stores info about that:

This SQL statement gets all the IDs of all delegations a user has set for today:

SELECT DelegationID FROM NW2013DB.dbo.Delegation

WHERE Username = 'i:0#.w|devdeveloper'

AND StartDate <= GETDATE()

AND EndDate >= GETDATE()

Save the result (list of IDs) in a collection variable. If the user has no delegation set for the specified time period, the collection variable will be empty after the sql statement.

Regards

Philipp


Reply