As mentioned, the example above is a simplification, actually it is really difficult for me to obtain the 2nd table as a SQL query (which I think you would consider to be the sub-dataset). On the other side, the crosstab does it really easily, that's why I would like to use the crosstab output as input for a bar chart. Is it possible?