cancel
Showing results for 
Search instead for 
Did you mean: 

Task without Process

frankee787
Champ on-the-rise
Champ on-the-rise
As per the javadoc


[b]newTask[/b]

Task newTask()
Creates a new task that is not related to any process instance. The returned task is transient and must be saved with saveTask(Task) 'manually'.

Is there a means to retrieve ONLY tasks not associated with any process?

I tried

taskService.createTaskQuery().processInstanceId(null).taskAssignee(userId)
taskService.createTaskQuery().processInstanceId("").taskAssignee(userId)

but neither of them seem to work for me.
2 REPLIES 2

mhdshahdoost
Champ in-the-making
Champ in-the-making
you must save new Task with one of your process Instances and after this work you can work with this Task :


    engine.getTaskService().saveTask(Task);

frankee787
Champ on-the-rise
Champ on-the-rise
I am saving the task. I can see it in the database.

But on retrieving it , it comes along with the processes associated tasks. I would like to retrieve the NON-PROCESS associated tasks separately.

Regards,
Franklin