Created public final static string class name. That way each instance will have the same type name when getType() is called.
Fixed some SQL and stylistic inconsistencies.
Merge commit '3b132436d5e91fb933177ed8f9b185f73105e6fb'