cancel
Showing results for 
Search instead for 
Did you mean: 

SAC - Adding transactional data with API method Planning.setUserInput() fails

mfrieser
Participant
0 Kudos
1,206

Hello,

I am struggling with the setUserInput() method.

In my Analytic Application, I create a new dimensional member and I want to pre populate this member with a value.

My model is quite simple:

  1. PROJECT
  2. LineItem
  3. Version
  4. Date
  5. Measure: Volume

When adding data with this code

LineItemsTable2.getPlanning().setUserInput
({ "@MeasureDimension": "Volume","LineItem": lineItemID, "PROJECT": ProjectSelection, "Version": "public.Plan",
"Date": "202301",
//"RunningNumber": ConvertUtils.numberToString(runningNo) // this is a property of LineItem, shown in Table
}, "12345");

I get the following message:

Sorry, we couldn't carry out your data entry because one or more conditions for entering data haven’t been met.

This is a more detail log from the debugging console:

[FailedAction - Action: SET_DATA@[{"app":"MAIN_APPLICATION"},{"story":"storyID"},{"table":"b925927c-7723-4aec-aa1d-cd87e68defa8"}] - Error: 132/] 
code: 132
action: ObjectinstanceId:
e {idStr: '[{"app":"MAIN_APPLICATION"},{"story":"storyID"},
{"table":"b925927c-7723-4aec-aa1d-cd87e68defa8"}]
', lastPair: {…}, debugKey: '[{"table":"b925927c-7723-4aec-aa1d-cd87e68defa8"},
{"app":"MAIN_APPLICATION"},{"story":"storyID"}]'}
selectedData: CustomDimension1: {id: 'Volume', desc: '', level: 0}
Date: {id: '202301', desc: '', level: 0}
LineItem: {id: '534102P-21', desc: '', level: 0}
PROJECT: {id: '00001', desc: '', level: 0}
Version: {id: 'public.Plan', desc: '', level: 0}
[[Prototype]]: ObjectstoreEntityType: "table"type: "SET_DATA"value: "12345"[[Prototype]]: Object
devMessage:
sourceFailure: undefined

It is somehow confusing to me that the MeasureDImension is called "CustomDimension1" in the log.

I also tried different date formats. like

[Date].[YM].&[202301] or [202301]

I appreciate any help.

Thanks!

View Entire Topic

Check whether your table resultset inlcudes the cell you are trying to submit data. Sometimes if the cell has no data, you will also face the error because by default the unbooked values will not show in the table, try to show unbooked values in both row/column axis in this case.

mfrieser
Participant
0 Kudos

Hello Lilu,

the resultset does not contain any data, as the new dimensional member is created shortly before the setUserInput method call. Maybe this is the error.

andreamilano89
Explorer
0 Kudos

Hi, I'm facing the same issue as Michael. I tried to set unbooked data as visible in the table (rows and columns), but I still get the same error "Sorry, we couldn't carry out your data entry because one or more conditions for entering data haven’t been met.".

Could you solve it some other way, Michael?

Thanks!!

mfrieser
Participant
0 Kudos

Hello,

no, unfortunately not. I used a data action instead.