The process of modulation is done by using a pivot chord, a chord that exists in both the original key and the key your going to. As for G existing in 7 different keys, this is true but as a chord, say G maj it's only in 3 keys. You'll have to take in count the chord structure. Now when you add an extension like a 7th, G maj7 occurs only twice, and G dominant 7 (G7) only occurs once. Seems hopeless cause there are two things that will help alot. One is a chord progression common in all music, it's the two-five (ii-V7) which occurs naturally in the major key. Then there's the other two-five which are both dominant (II7-V7). This is what makes most modulations possible, including the cycle 5 chord progressions. Here's the dominant one (III7 - VI7 - II7 - V7), each time you play a dominant technically your in a different key. The other way is with line cliches, which is having a chord progression like Gmaj7 to G7. A oline cliches is when the root chord (Gmaj) stays the same but the extension moves (maj7 to dominant 7). As you can see this will make a connect where most modulations can't occur naturally. I'll take the explain from clapton and change it alittle to show what I mean.
Fmaj7 - G7 - Gmaj7 - A7
Starts off in the key a C major with Fmaj7 and G7, now using a line cliches of G7 to Gmaj7. Now I play a A dominant 7 and I am in the key of D major. Gmaj7 was the pivot chord.
There are many techniques to make modulation possible. Those 2 will pretty much answer most. Some just have to change without a pivot chord.
"My whole life is a dark room...ONE BIG DARK ROOM" - a.f.i.