I'm attempting to use the bulkloader to load data into my app. I have
my loader/exporter set up with the following classes:

class FoodItemLoader(bulkloader.Loader):
  def __init__(self):

    bulkloader.Loader.__init__(self, 'FoodItem',
                               [('author', str),
                                ('name', str),
                                ('brand', str),
                                ('price', str),
                                ('category', str),
                                ('stores', list)
                               ])

class FoodItemExporter(bulkloader.Exporter):
  def __init__(self):
    bulkloader.Exporter.__init__(self, 'FoodItem',
                                 [('author', str, None),
                                  ('name', str, None),
                                  ('brand', str, None),
                                  ('price', str, None),
                                  ('category', str, None),
                                  ('stores', list, None),
                                 ])

exporters = [FoodItemExporter]
loaders = [FoodItemLoader]

---

The exporter seems to work fine, and it exports a column with the
following type of data in it for the stores list property
"[datastore_types.Key.from_path(u'Store', 3002L,
_app_id_namespace=u'grocerygeek')]"

Unfortunately, I cannot use this same format to load data into my
datastore because it gives me the following error "BadValueError:
Items in the stores list must all be Key instances"

Is there a way I can format my CSV file or my code to accept this type
of data?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to