Solar water heaters and gas water heaters can be combined.
It's just that this combination doesn't make much sense. If you use a gas water heater only to produce hot water on cloudy and rainy days while the solar water heater cannot heat water normally, there is no problem.
If the hot water heating pipes of solar water heaters and gas water heaters are used in series, big problems will occur, which can easily lead to heater failure water to gas.