Even though it has more $\ce{OH}$ groups and still it is very weak in terms of dissolving?
please clarify to me in terms of polar and non polar solubility, how to determine whether a compound is soluble or not in water.
$\ce{OH}$ is small anion and bonds effectively with small cations. Thus, in general, the bigger (and less specific charge) of the cation, the higher is solubility of the corresponding base in polar solvents, meaning that $\ce{Ca(OH)_2}$ and $\ce{Al(OH)_3}$ having much smaller and more charged cations are almost covalent in nature and thus, do not dissociate.
In general, solubility of salt in water is determined by energy balance between breaking of the ionic bonds and hydratation of anions formed. Thus, the most soluble salts are usually formed by small and big ions, that cannot bond effectively, but at least one of them can be hydrated effectively.
Please, note: solubility for molecular compounds, like sugars and some non-dissociating compounds that looks like salts (like $\ce{Cu(CH_3COO)_2*H_2O}$) is an entirely different matter and determined by relative strength of intermolecular interactions (read: the molecule have to be able to form hydrogen bonds)