I can see now what the problem is. Originally I thought that the problem was with
Implicit Transactions[
^].
Now, I can see that you are trying to execute a SQL statement on a cursor object. You can't do this. The whole purpose of a cursor is to scan it row by row.
Instead of writing:
Set @Group_Name = (SELECT TOP (1) Group_Name FROM Beach_Group_Names ORDER BY NEWID())
You need to open Beach_Group_Names cursor and include it to the FETCH NEXT, like this:
Fetch NEXT from Beach_Group_Names into @Group_Name
I don't see where you open the Beach_Group_Names cursor, so I guess it should be opened inside the top cursor Team_IDs