Hi..
I am trying to load some initial data using yaml. My model in utils
is
from django.db import models
class Months(models.Model):
id=models.CharField(primary_key=True, max_length=3)
m_name=models.CharField(max_length=15)
class Admin:
pass
My yaml file is
- fields: {m_name: 'January'}
model: utils.month
pk: jan
- fields: {m_name: 'February'}
model: utils.month
pk: feb
- fields: {m_name: 'March'}
model: utils.month
pk: mar
- fields: {m_name: 'April'}
model: utils.month
pk: apr
When I try to load this data, It returns error
Loading 'initial_data' fixtures...
Installing yaml fixture 'initial_data' from 'fixtures'.
Problem installing fixture 'fixtures\initial_data.yaml': Invalid model
identifier: 'utils.month'
I tried model: utils.Month too, but the result is the same It then
says invalid model identifier utils.Month . Please advice.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---