The PowerMac G5 has used two kinds of RAM during its model life that are incompatible. DDR2 will not work in the DDR G5 and DDR won't work in a DDR2 G5. To find out which you have:
DDR (top) is keyed differently from DDR2 (bottom), so you have to determine which you have before you order an upgrade.
Select "About This Mac" in your Apple Menu.
DDR SDRAM means you have the "Original" PowerMac G5 DDR
DDR2 SDRAM means you have the "Dual Core" PowerMac G5 DDR2