I have written a query which returns a table (tb1) with rows of data. One column shows a list of queues an analyst can work on and the other columns show how many analysts are available to work on those queues and how many are away.
I now need to wrap this query in another so it returns the row, broken down into multiple rows each showing how many analysts are avail/away per queue.
UPDATE - I have created this post when there are similar ones out there because the Queue column is the key, which needs to be separated into individual rows each with the same data from the other (avail/away) columns when it was just one row. To add complexity there can be some rows with more/less queue names that need grouping. example is updated.