Use both if you can, depending on your setup... just make sure that any unions between the two are strong and water tight. Let all cement dry for at least a couple hours before turning water on.
This way, your connections will be a bit forgiving. If you have an external pump (not submerged in water) then I would go all rigid PVC
. I use flex and rigid with my submerged pump and it works great!