Hello,
I have an app using multiple sharepoint lists that hold information for different types of items and their costs. Some of these items can be components of other items. I have a link table for these Parent-Component relationships that holds the primary ID for each and the "CategoryID" for each, which tells me which table that item belongs to. However, when updating prices of components, I have the price updating in the link table, but now I need to update the price of the parent item.
The problem I am facing is how to use a calculation to determine which table the parent item is located. Right now, I have 5 item tables and don't anticipate adding more so I could use If statements to match the category ID to the right table (If CategoryID = 1, Patch Table1), but I am hoping there is an easier way.
It might also be worth mentioning that after updating a price, I use GroupBy to create a collection holding all the link information for each unique parent/category and added a column to Sum up all the grouped prices. I just need to be able to easily patch that price into the correct table without too much effort.