Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I have 2 tables Orders and suborders.
I have a straight table with orders as dimension and some expressions. And what I want to show is the description of the next suborder.
I think I have to create a field in the script in the Orders table, which saves this for me.
I don't find a way to show it in the table. I can show the max(ID_suborder) and the number of suborders to come. So i could calculate the ID_suborder for the next suborder. Something like =max(ID_suborder) - open_suborders + 1 ...
open_suborders = count(IF(Status=1,suborder)) ... just for the record.
But even with this number I'm not able to show the description.
I tried this IF(max(ID_suborder) - open_suborders + 1 = ID_suborder, Description,'No Orders') ... Its not obvious for me why this don't works.
Do I have to code this into the script and generate an extra field? I can't believe that this can be so hard to show.
I think it should be the first ID_suborder with Status=1
Thank you for any hints..
Try: FirstSortedValue({<Status={1}>}Description, SubOrderID)
See attached example.
hmmm nobody has a clue how to solve this?
My Table looks like
Order | Open Sub-Orders | Sub-Order Total | Next Open Sub-Order |
---|---|---|---|
10000 | 1 | 2 | ? |
10001 | 5 | 23 | ? |
Problem is the "Next Open Sub-Order" column I would like to show the Desc. of the next suborder.
Every sub-order has an ID and a status field which is unique within the order no, so I can calculate the sub-order ID like described above, but an IF Statement like "IF([sub-order ID] = Total - Open, Description, 'No Open Sub-Orders') does not work...
Is there any function which could do the trick?
Hello,
Your question could be answered with a bit clearer explanation i believe. Though you have explained in your way, it has not reached most of the people like me. Can you please come up with your tables and sample data along with the expected result explained?
Hi tres qv,
i created a qvw with some sample data and a straight table. The fields/expression I need help with is marked red. The (not working) expression is quite simple (and i commented it in the properties/expression dialog).. I think it should make clear what I want to be shown in this field.
Thanks for your help.
Try: FirstSortedValue({<Status={1}>}Description, SubOrderID)
See attached example.
PFA
Thank you for your help. It works great. I tested firstsortedvalue too, but obviously I did something wrong.
Gysbert you are a machine!
thank you guys for making my day...