Hi,
it would be nice if the view V_WFElements would not only contain the integer id but the GUID.
I'm not sure whether using the view in a calculated column would be more performant or creating an own join, but only for one table.
For example
(select Count(*) from V_WfElements childs where childs.DTYPE_GUID = '0000' ... further conditions)
vs
(select Count(*) from WfElements childs join WFDocTypes on childs.WFD_DTYPEID = DTYPE_ID and DTYPE_GUID = '0000' where .... further conditions)
I didn't test this query so it may be off and there could be syntax errors, but I think it's clear what I want to tell.
Best regards,
Daniel