Fixes #916: generation of class name from table name has problem.