View Issue Details

IDProjectCategoryView StatusLast Update
0001617phplist applicationSubscriber Importpublic23-10-04 23:13
Reporterduncan 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version 
Target VersionFixed in Version2.9.2 
Summary0001617: Imported attributes that are blank do not get assigne an attribute value
DescriptionWhen importing a list with e.g. [first name] as an attribute if the first name is blank for an individual user no user_user_attribute record is created for it. This means when sending to that list and using [first name] as a placeholder in the email will produce [first name] as the literal output rather than blank.
There is no mechanism to create these missing records easily and so users get [first name] or whatever the placeholder is carried through to their email
Additional Informationphplist 2.8.10 running debian linux stable use browser Mozilla Firefox 0.9
TagsNo tags attached.

Activities

michiel

23-10-04 23:13

manager   ~0002370

temporary patch:

in import2.php where it says
            Sql_query(sprintf('replace into %s (attributeid,userid,value) values("%s","%s","%s")',
              $tables["user_attribute"],$attribute_index,$userid,$user_att_value));
          }

change it to

            Sql_query(sprintf('replace into %s (attributeid,userid,value) values("%s","%s","%s")',
              $tables["user_attribute"],$attribute_index,$userid,$user_att_value));
          } else {
            # add an empty entry if none existed
            Sql_Query(sprintf('insert ignore into %s (attributeid,userid,value) values("%s","%s","")',
              $tables["user_attribute"],$item["record"],$userid));
          }