Compositions for consolidating loose sand or the like around wells without excessively decreasing the permeability thereof