The sun also affects the tides, albeit less so than the moon, by attracting masses of water. The solar role is additive to the lunar one therefore, the respective geometry also influences the tides.