Jump to:

23374 Posts in 18175 Topics by 2866 members

General Questions

SilverStripe Forums » General Questions » CSVBulkImporter inserting empty relational object with relational callback function

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 291 Views
  • r0nn1ef
    Avatar
    Community Member
    6 Posts

    CSVBulkImporter inserting empty relational object with relational callback function Link to this post

    I've written three or four DataObject models as well as using the ModelAdmin and CSVBulkImporter to import data for my new models. I've seem to run across and issue that doesn't make any sense to me.

    One of the csv files being imported contains 32K(+/-) records and when I import the file, one of my relational mappers always inserts a new record for the relation with no values; the relational mapper isn't finding the existing relational record. BUT, however, if I reduce the number of records in the csv file (i trimmed it down to 1000 records plus the header row), it works just fine.

    I looked at the code in the CSVBulkLoader class and the code makes sense and should work fine (as is proven in my reduced row count in the import). Is there something I'm missing, don't know, or don't understand about how the bulk loader process works that would cause this? Or is it a database error of some sort?

    291 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.