I have a G2 and was wondering if it's possible to upgrade to android 2.3 or do you have to just buy a phone (like the nexus s) that already has the OS installed?
Yes. Android supports free updates including the upcoming gingerbread. You can update it from your phone and you do not need to buy a new phone that comes with the the software. As new updates come, especially big ones, you are going to need the powerful hardware to support it. But the G2 is recent and strong enough to be able to support large future updates.