1. hatbe7
  2. Support
  3. Tuesday, October 04 2016, 05:13 PM
Hi,

I am using import plugin 1.1.0 and tweaked it a bit to check duplicates not only on email:

// Check if user already exists
$query=$db->getQuery(true);
$conditions = array(
$db->quoteName('username') . ' = '. $db->quote($userRow['username']),
$db->quoteName('email') . ' = '. $db->quote($userRow['email']),
$db->quoteName('name') . ' = '. $db->quote($userRow['firstname'] .' ' . $userRow['lastname'])
);
$query->select('id')->from('#__users')->where($conditions);


what i experience is that the validation (row

// Check known fields
...
if(!in_array($field,$this->j_fields) && !in_array($field,$this->jsn_fields))

always fails on the first column... I changed order of the columns and verified that all fields indeed are included in the file

any idea?


Thanks
Accepted Answer
admin Accepted Answer
Admin
Hi,
- downloaded
- rename with extension from txt to csv
- opened with excel

see result in screenshot

I recommend you to delete entire first line and re-write (by hand, not with copy/paste)
Attachments (1)
  1. more than a month ago
  2. Support
  3. # Permalink
admin Accepted Answer
Admin
try to open your CSV file with Excel and check if first column declaration is ok...sometime as first char there is something of strange
  1. more than a month ago
  2. Support
  3. # 1
hatbe7 Accepted Answer
i checked with excel and checked via text editor. file is a txt (semicolon delimited) and UTF8 encoded
  1. more than a month ago
  2. Support
  3. # 2
admin Accepted Answer
Admin
can you send me your file? only with 1/2 example row.

NOTE: to send file you need to compress into .ZIP, this forum does not accept .CSV
  1. more than a month ago
  2. Support
  3. # 3
hatbe7 Accepted Answer
file attached
  1. more than a month ago
  2. Support
  3. # 4
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.