cancel
Showing results for 
Search instead for 
Did you mean: 

IDM 7.0 - Problems with Template-Script "Approve and decline notification"

Former Member
0 Kudos

Hello

I'm currently messing around with the template/script "Java - Approve and decline notification".

The "Notify Approvee" task is started as an "Execute task on OK result" from an Approval task which is a child task of task "ProvisionADS".

Humm, this'll get quite complicated to explain

When it comes to the part (source-code comment) "//Get Approval Operation" the script issues a SQL-command to the IC-Database:


var SQL = "select substring(avalue,8,CHARINDEX('!!',avalue,0)-8)as OPERATION from mxiv_oentries where AttrName = 'MX_Approvals' and aValue like '%AUDITID=<" + AuditID + ">%' and aValue not like 'STATUS=WAIT%'";
OutString = UserFunc.uSelect(SQL);

This returns an emtpy string / null value.

In my case the above code-variable "AuditID" has the Audit-value of the task "Java - Approve and decline notification" (the currently executing task) which I can verify in "Monitoring -> Provisioning audit -> column Audit ref".

When I view the table "MXIV_OENTRIES" - column "aValue" - I can see that the code-variable "AuditID" should have the value of "Monitoring -> Provision audit -> column Audit root", which holds the "Audit ref" from the task "ProvisionADS".

Currently I have no idea how I can resolve the "Audit ref" / "AuditID" of the root task "ProvisionADS" in my "NextNotification"-script.

Any ideas?

Regards,

Michael

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi again

I feel like stupid:

The last line in the NextNotification-Script supplies parts of the answer:


UserFunc.uSelect("select auditroot from mxpv_audit where auditid=" + AuditID);

Nevertheless I'm puzzled why this line of code is not called in the right place...

Question solved

Edited by: Michael on Jul 8, 2009 3:51 PM