" Assignment error: Overwriting a protected field".
<b>Requirement:</b> We have to populate time-characteristic field(cal quarter) based on fiscal period in the planning layout.
<b>Effort:</b>Formula doesn't seem to help as it doesn't give ability to manipulate character strings. So we tried with user exit. In user exit when tried to populate field fiscal quarter based on fiscal period, we're getting error" Assignment error: Overwriting a protected field". It seems like key figures can be manipulated without this problem but not characteristics , as modifying xth_data table is failing. Also couldn't find any example given by SAP under function group UPFX.
Did anybody face this problem or any suggestions?
Anand Jain replied
Hi,
I think you are trying to change the values directly in XTH_DATA, which is not possible as XTH_DATA is a hashed internal table with all the characteristics as key fields. You will have to take all the entries from the table into another internal table defined in the function module perform the required operation (changes to values) pass the entries back to XTH_DATA
XTH_DATA = internal table.
let me know if this was helpful..
thanks