The community will be in read-only from Tuesday 11:59pm (PST) to Wednesday 7:30am (PST)
The community will be in read-only from Tuesday 11:59pm (PST) to Wednesday 7:30am (PST)
Project and Portfolio Management Practitioners Forum
cancel
Showing results for 
Search instead for 
Did you mean: 

ksc_store counter

SOLVED
Go to solution
Highlighted
Scott A Wood
Regular Collector

ksc_store counter

I am trying to increase a counter in a Request Type field with the name "PASS" (number field) which is already initilized to the value of 0 using a workflow execution step.  I've tried both of the options below, but after the step completes, the PASS field value is changed to null or spaces.  Any suggestions on what I'm doing wrong?

 

Option 1:

ksc_run_sql QUERY_STRING = "Select [P.PASS] + 1 From DUAL" ENV_NAME="[WFS.SOURCE_ENVIRONMENT_NAME]"
ksc_store PASS = "[SQL_OUTPUT]", "[SQL_OUTPUT]"

 

Option 2:

ksc_run_sql QUERY_STRING="select [P.PASS] + 1 from dual" ENV_NAME="[WFS.SOURCE_ENVIRONMENT_NAME]"
ksc_store PASS="[SQL_OUTPUT]"

3 REPLIES
Scott A Wood
Regular Collector

Re: ksc_store counter

Looking at the execution log, it looks like it is trying to throw the text into the field.

PASS="[SQL_OUTPUT]", "[SQL_OUTPUT]"
hyllplan
Frequent Visitor
Solution

Re: ksc_store counter

[P.PASS] should be [REQD.P.PASS] if request type.
Also are the source environment defined in the workflow step?
Search manual for workflow tokens (WFI.P.*) If I remember correctly there is an example describing exactly what you want to achieve
Johan
Scott A Wood
Regular Collector

Re: ksc_store counter

I had missed the adding the enviroment to the workflow step.  Once I added that in, everything else worked.

//Add this to "OnDomLoad" event