db tables fields auto-generated bugfixed