You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
so, RandomName in Food might be something different than RandomName in Specials, therefor I need to check WHERE Category = $Category AND Title = $Title
but with the current implementation just using
public $duplicateChecks = array('Category' => 'Category', 'Title' => 'Title');
would not work here, because it would consider a Unicorn Horn a duplicate of A scale of Zauberfisch, which clearly is wrong.
I can workaround using a callback on a single value (eg. Title) and perform both checks in that callback, but shouldn't the CsvBulkLoader be able to to handle this usecase?
what are your thoughts on that? If I get some input and we agree on a way to implement it, I am happy to do it.
The text was updated successfully, but these errors were encountered:
after some conversation in IRC, I think it stands to consider if this even still has a reason to exist.
considering how easy doing this with a datalist is now (->filterAny(array('Title' => $title)))
another point to deprecate this is that it is not consistent and misleading,
I just discovered that 'Name' => 'Title' actually completely ignores Name and only uses Title on both the CSV data as well as in the Database
only when using 'Name' => callback then the Name is used
currently the $duplicateChecks check as OR, so lets say you have:
this would basically do a SQL:
WHERE ID = $ID OR Title = $Title
but a OR might not always be the desired condition.
lets take a product import:
so,
RandomName
inFood
might be something different thanRandomName
inSpecials
, therefor I need to checkWHERE Category = $Category AND Title = $Title
but with the current implementation just using
would not work here, because it would consider a
Unicorn Horn
a duplicate ofA scale of Zauberfisch
, which clearly is wrong.I can workaround using a callback on a single value (eg. Title) and perform both checks in that callback, but shouldn't the CsvBulkLoader be able to to handle this usecase?
what are your thoughts on that? If I get some input and we agree on a way to implement it, I am happy to do it.
The text was updated successfully, but these errors were encountered: