class Migration(SchemaMigration):

    def forwards(self, orm):
        db.rename_table('usergroups_myuser_group', 'usergroups_myusergroup')

def backwards(self, orm):
    db.rename_table('usergroups_myusergroup', 'usergroups_myuser_group')
models = {'usergroups.myusergroup': {'Meta': {'object_name': 'MyUserGroup'},
    'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}
    ), 'name': ('django.db.models.fields.CharField', [], {'max_length':
    '100'})}}
complete_apps = ['usergroups']
Renaming a django model class-name and corresponding foreign keys with south, without loosing the data