Normal I'm looking for tasks as follows:
#Inject
TaskService taskService;
taskService.createTaskQuery()
.processDefinitionKey(ProcessVars.PROCESSKEY)
.taskCandidateGroupIn(list).initializeFormKeys().list();
How do I filter by age? Tasks older than 3 weeks as example. By HistoryService?
Thanks for help.
You can use the TaskQuery taskCreatedBefore or taskCreatedBeforeExpression methods. With the second you can use an expression like "${dateTime().minusWeeks(3)}" which will calculate the date for you.
Related
can I configure for “retry time cycle” many different interval expression for example
something like that: “R6/PT10S, R2/PT30M” - 6 times each 10 Seconds and then 2 times after 30 minutes
Thanks in Advance,
Wladi
The job executor section of the camunda user guide only shows an example of comma separated intervals without repeats.
Looking at the code it seems a repeat is only recognized if there is a single interval configured
https://github.com/camunda/camunda-bpm-platform/blob/7.13.0/engine/src/main/java/org/camunda/bpm/engine/impl/util/ParseUtil.java#L88
The lookup of which interval to apply also does not consider any repeats
https://github.com/camunda/camunda-bpm-platform/blob/7.13.0/engine/src/main/java/org/camunda/bpm/engine/impl/cmd/DefaultJobRetryCmd.java#L113
This sounds like a useful feature though, you might want to open an issue in the camunda issue tracker.
I have a SAS dataset with the transcription of a web chat in one row
Example here:
conversation id = 346768584212
Transcript =
11:13:57 info: Thank you for choosing to chat with us. An agent will be with you shortly...11:13:58 info: You are now chatting with Harsh...11:14:00 Shahid: Hello..11:14:03 Shahid: HI Harsh..11:14:25 Shahid: I have received two customers numbers one for personal banking and one for business banking..11:14:30 Harsh
I'd like to use SAS to split this out so that there is one row per message
Example:
conversation ID
346768584212
346768584212
Message
11:13:57 info: Thank you for choosing to chat with us.
11:14:03 Shahid: HI Harsh..
Cant figure out how to split it by timestamp - any advice would be much appreciated
Thanks
Tom
should be pretty easy to do. Here's a reference:
sas regular expressions
check out PRXNEXT on page 12. your regular expression would be "/\d\d:\d\d:\d\d/"
I created a schedule in IBM OPL:
dvar sequence schedule in all(j in Jobs) job[j];
If the CP-Module generates a solution, the solution is sometimes not a non-delay solution. This is however not allowed and thus I want to enforce a non-delay schedule.
I tried different solutions in the subject to-Section...
forall(t in Jobs)
if (t > 1)
startOf(job[t]) == endOf(job[t-1]);
... but these fail (obviously) when job t-1 is not followed by job t.
Anyone who can give me a hint on how to solve this problem?
Kind regards,
Franz
you should try to use endAtStart.
(OPL constraint to restrict the relative positions of interval variables.)
regards
endAtStart will only work if your Jobs are always ready to start when the preceding Job finishes. If this is not the case, you will receive an error.
A better solution would be to regard the no-delay in the objective. What you are trying to achieve is to start every new job as soon as possible. So you can for example use the staticLex function:
minimize staticLex(startOf(job[1]), startOf(job[2]),...);
However, this expression can become very long and you would need to hardcode the number of intervals.
A little workaround would be to assign the intervals decreasing weighting factors:
minimize sum(j in Jobs) startOf(job[j])*100^-ord(Jobs,j);
I hope this works for you!
Regards
Jan
I have a sheet that has become complex, it has a lot of filters and I need to populate a table with data. I am counting how many times a month we run a product. If we run it once a day, or more, I want to only count that as one.
Date Product Grizzly
1/1 2.5 open
1/1 1.5 closed
1/1 2.5 closed
1/1 2.5 open
Something a little more elaborate than this, but what I need is to count this as one day of 2.5 grizzly closed, instead of two.
Any help? I feel like there is something simple I am missing but cant put my thumb on it and I have spent well over 15 hours working on this.
As found on the following link:
Link to Answer
Try using the DCOUNTA function within Excel.
Although I'm also sure that you could use a pivot chart to provide the same outcome.
EDIT:
I am assuming you are starting with data like the following:
I then created the following table which you can extend to comply with you total data value. For example, you can add extra dates and products.:
The table is populated using a COUNTIFS function.
=COUNTIFS("DateRange",DateCriteria, "ProductRange", ProductCriteria, "GrizzlyRange", GrizzlyCriteria)
So in my table the formula looks like this but the cell references will obviously changes according to your spreadsheet (I used absolute references to make it easier to use the fill handle to copy the formula down:
=COUNTIFS($A:$A,$E4,$B:$B,$F$3,$C:$C,$F$2)
I next nestled this formula in to an IF statement and applied a conditional formatting to end up with the following:
So the formula for each of the cells is now:
=IF("OriginalFormula),"Yes","No")
Example of my 01/01/2015, 1.5 open value:
=IF(COUNTIFS($A:$A,$E4,$B:$B,$F$3,$C:$C,$F$2),"Yes","No")
BUT - You can change the "Yes" and "No" to "1" and "0" if you want to stick with numerical values.
I have a task where i will receive the schedules like below( Example ):
3,5,6 ( represents days of a week )
9:30 - 13:45, 15:12 - 18:75 ( Time Slots )
These days and slots are applicable for an year or more.
We are currently storing them in a config file. So, i have to start a task based upon these schedules i.e., on 3rd day of week at 9:30 i have to start the task and suspend it once it reaches 13:45.
We are using C++ for our prod. We cant use boost for now.
Q: What do you suggest is the best way to achieve this? I have implemented in a way where basically split( must ) and then comparing with system date which has lead to a cumbersome code and buggy to some extent.
I believe people would have faced similar issues earlier. Iam concentrating more on best approach to cover all boundary cases like end of day, start,leap,non leap. Any best and efficient approach do you people suggest with your experience?
Thanks~
Santhosh
I did my own petty\pretty scheduller to go around this. So far so good working with this!!