Looks like there’s two requests here:
Rafael_ANEIC-PY:
i’d like to pull a list of unique ids from [TABLE A], and be able to use that list of ids using the context of [TABLE B] for the columns inside said start expression.
For this, it sounds like what you need to do is extract from your orders the list of products selected - then you want to use that list inside a <<START: in a workflow so that the product details are displayed in the workflow instead of the order details.
For this, check out List dereferences:
I’m assuming you’ve got an Order parent level, and then order details where people select the individual products they want (and quantity, etc.)…
- On the Order Parent, you’ve got a [Related OrderDetails] - a virtual column that’s a list of all the related OrderDetail records
- From this, use a List Dereference formula to pull out the Product values.
[Related OrderDetails][ProductID]
This will product a list of all the values in the [ProductID] column for all the related records.
With this on the Order level, you can then use this column’s values inside your <<START: expression
<<START: SELECT(Products[ProductID],
IN([ProductID], [_ThisRow].[Products_From_OrderDetails]))>>
The second question
Rafael_ANEIC-PY:
In my case i need to display all the items that the customer is able to buy, even those that he hasn’t purchased, that list of all products is in [TABLE A], and the individual item purchase records are in [TABLE B].
For this one, take a look at List dereferences and list math (addition/subtration)
You can easily create a list of the products selected (list deref from the OrderDetails), then take the master list of products and subtract from that the items the person has already selected.
- this would give you a list of products that haven’t been selected by the user.
Alternatively, if you added the Master List to the list of products selected by the user;
- you would end up with a list of all the products (because you took what the user selected… and added everything to it).