Skip to content
Advertisement

Dynamic columns from two tables

i need some help. I would like to combine two tables in sql with dynamical columns. Here my thoughts:

Table one:

Example Table jrincidents

Table two:

Example Table jrusers

reporting like

i don’t know how to dynamically add the steplabels from table jrincidents as columns of jrusers if where processname = x

Thanks for helping

ADD:

Let me try again

The Result should look something like that

Result

The department and steplabel should be dynamic like a filter.

If i change the processname to “rechnungseingang” the select should chose the different steplabels and departments dynamic from a subtable row as a column in the select. Like a move from vertical(row) to horizontal(column).

Data Table:

Advertisement

Answer

I wrote a procedure:

User contributions licensed under: CC BY-SA
5 People found this is helpful
Advertisement