Hi,
I wouldn't store the value in table1, but it can be worked out dynamically by running this query:
select T1.KategorieIdx, T1.Kategorie, count(T2.KategorieIdx)
from table1 T1, table2 T2
where T1.KategorieIdx = T2.KategorieIdx
group by T1.KategorieIdx, T1.Kategorie
You can expand this further, let's say you only want to see records where there is a count > 2
select T1.KategorieIdx, T1.Kategorie, count(T2.KategorieIdx)
from table1 T1, table2 T2
where T1.KategorieIdx = T2.KategorieIdx
group by T1.KategorieIdx, T1.Kategorie
having count(T2.KategorieIdx) > 2
Hope this helps
Mike