Jump to:

5539 Posts in 1738 Topics by 1224 members

Customising the CMS

SilverStripe Forums » Customising the CMS » CsvBulkLoader::$duplicateChecks doesn´t work

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

Page: 1
Go to End
Author Topic: 1103 Views
  • baba-papa
    Avatar
    Community Member
    279 Posts

    CsvBulkLoader::$duplicateChecks doesn´t work Link to this post

    Hi,

    I extended the CsvBulkLoader and don´t want duplicates in my database.

    public $duplicateChecks = array(
    'Studioname' => 'name'
    );


    The values of the CSV column Studioname should be compared with the connected objects attribute "name". If I import the same CSV file twice all data sets will be doubled. I want existing data sets to be overwritten.

    Any help to this issue is appreciated.

  • baba-papa
    Avatar
    Community Member
    279 Posts

    Re: CsvBulkLoader::$duplicateChecks doesn´t work Link to this post

    Does duplicateChecks work only with a primary key?

    1103 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.