COUNT: Course_ID
11 1234
12 2323
19 8932
I want to populate a NUM_REG field in another table with the COUNT from this query to the records that have matching Course_IDs.
Similar to this situation:
Expand|Select|Wrap|Line Numbers
- update a
- set a.cnt = b.cnt
- from table2 a,
- (select widget_type, count(*) as cnt
- from table1
- group by widget_type) b
- where a.widget_type = b.widget_type
Any suggestions?