CaseWhenThenElseEnd function is not working for non-administrato
SummaryUser used CaseWhenThenElseEnd function as a column in a report definition and used this Report Definition (RD) as a source of the repeat grid in a section.
In a repeat grid cell they have added the property calculated by CaseWhenThenElseEnd function like this:
@@pxDifferenceInDays(.pxCreateDateTime,@@pxCurrentDateTime()) . The grid cell has been chosen as a "Text input" type control.
Error MessagesThe reference .@@CaseWhenThenElseEnd(CustomerOrder.CaseID,CustomerOrder.CaseID,.pxRefObjectInsName) is not valid. Reason: unexpected character '@' at position 1, expected start of name
Steps to Reproduce
- Private Edit the RD pyGetWorkBasket.
- In the RD add a row in the Query tab and use the function builder to refer function: @@pxDifferenceInDays(.pxCreateDateTime,@@pxCurrentDateTime()) which calculates the difference in days between .pxCreateDateTime and .pxCurrentDateTime.
- Refer this RD as data source for a Repeat Grid.
- In the Repeat Grid refer the function.
- Save and Run the section containing the Repeat Grid.
Root CauseThe issue is in custom configuration. The cell in the repeat grid is chosen as the Text input type control. This caused the issue and the error was thrown.
Apply the following local change to resolve this issue:
Delete the problematic column from the repeat grid and add a new one to show the calculated value like this:
Here the instead of forcing any control type the cell is allowed to inherit the control from the property.
Published September 2, 2016 - Updated September 21, 2016