To see the relationship between G and g, start with the general gravitational force equation as in the previous replies:
F = Gm1m2/r2
Suppose mass 1 is very large compared with mass 2 and that it has a very large radius (like mass1 is the Earth, say, and mass 2 is a ball near the surface of the Earth), so r is effectively just the radius of mass 1.
Then Gm1/r2 = g is virtually constant when dealing with objects much smaller than mass1 and near the surface of mass1. The force equation then simplifies to:
F = m2*g
or just F = m*g if we let the mass of the small object be m.
.
G is called the gravitational constant, whereas g is the gravitational acceleration.
.