Does anyone have any idea on how I can get a specific value from a record in Data Service without having to use a table control?
Let me provide you with some context… I have a data service entity that only stores a single record and the fields are used as some kind of reference for different scenarios, for example, one field stores the number of clients, that number is then used when I create a new client, so I collect the number and then sum 1 to the number so the data is always updated.
I have provided a solution on my own using functions like lookup and with the Data Context feature, but what if I want to get these values from an Event, How do I reference the value and set it to a variable of some kind?
I am wondering if someone has any better logic to achieve it.
That looks great
Hope you don’t mind answering these questions just to break down a bit.
Is LeaveType.Description a field of the Entity?
How is the “.LeaveType.Description” acting in the function? Cause if you would have left the expression as " LookUp(LeaveType,[LeaveType.Type, “=”, “Sick” ]) "
in that case, the output would have been the whole record object. So I guess that adding the “.LeaveType.Description” you are now able to also get the specific value from the field of the selected record. I’m getting it right? I just didn´t know you could add that extra step, and in the documentation, I guess I didn’t notice it. I’m still a beginner in expressions logic.