Question

6
Replies
1099
Views
Thomas Lorriette (ThomasL8)
Iriz Consulting
System Architect
Iriz Consulting
GB
ThomasL8 Member since 2016 17 posts
Iriz Consulting
Posted: March 19, 2018
Last activity: March 27, 2018
Posted: 19 Mar 2018 6:33 EDT
Last activity: 27 Mar 2018 11:44 EDT
Closed

Function working when running an activity, but not with an agent

Hello.



I'm trying to use the following in an activity:


@DateTime.addToDateYM(Param.CurrentDate,"0","-6","0","0","0","0")


(with Param.CurrentDate as a String or DateTime parameter, the problem is the same with both). The aim is to substract 6 months to the current date.



My activity is doing well when I run it but if an agent does, I keep having this message in the SMA:


Hello.

I'm trying to use the following in an activity:

@DateTime.addToDateYM(Param.CurrentDate,"0","-6","0","0","0","0")

(with Param.CurrentDate as a String or DateTime parameter, the problem is the same with both). The aim is to substract 6 months to the current date.

My activity is doing well when I run it but if an agent does, I keep having this message in the SMA:

** ** 1228138309§addToDateYM§PegaEL-InvalidExpression No candidates found [possible function name, ruleset/version or number of parameter problem] for Rule-Utility-Function in ruleset list expected since isEditing is false ruleset = null library = DateTime functionName = addToDateYM parameters =
[ Item: Param.CurrentDate Pega type = datetime Java data type = BigDecimal, Item: "0" Pega type = text Java data type = String, Item: "-6" Pega type = text Java data type = String, Item: "0" Pega type = text Java data type = String, Item: "0" Pega type = text Java data type = String, Item: "0" Pega type = text Java data type = String, Item: "0" Pega type = text Java data type = String] @DateTime.addToDateYM(Param.CurrentDate,"0","-6","0","0","0","0")
It seems that the agent doesn't find a candidate matching the function with its current parameters (the first one being the unrecognized one) but I tried everything and nothing work: @CurrentDateTime(), @today(), BigDecimalString or DateTime parameter, etc.
Any idea? I would like to avoid writting a java step just for that...

Data Integration Java and Activities
Moderation Team has archived post, This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.