two major issues I have come across post-upgrade from 3.2 to 3.3 in getting my site back up ---

1. the titles of all my nodes that existed in commons3.2 are blank, including groups, pages, posts, etc etc. I have gone through and pasted the main ones I need by hand, which is a pain. (edit node, remember what title should be, type/paste it in, save node. repeat x100 nodes) see screenshot attached of content list, no titles at all.
When I create a new node, or after I paste in the title for an old node, it does retain the title. but did not retain titles during the upgrade process.

2. most of the page manager configurations i had made seem to be gone. in one case the variants i created were still there but in reverse order. in most cases, my variants i created and changes i made to the default variants are nowhere to be found. I have no idea how to get these back, but I really don't want to have to recreate them from scratch. I believe my views panels are still available and made it through the upgrade, but I'd have to recreate the page. any ideas?

Yes, I did follow the upgrade instructions at https://docs.acquia.com/commons/upgrade

thanks.

Files: 
CommentFileSizeAuthor
commons_bug_notitles.jpg75.21 KBWebSinPat

Comments

Category:support» bug

anyone else experiencing this behavior? Or any of the developers have feedback for how i can get my node titles back without having to retype them all manually?
There seem to be some issues related to node fields getting blanked out that ezra was following, but I'm not sure if they do or don't have to with my disappeared fields since I dont think I have any language/translation enabled. mine had to do with the upgrade from 3.2 to 3.3
#1968162: Node titles set to empty strings #1811116: Title set to empty string when changing entity language to untranslated language etc .

I might be seeing similar behavior to the first issue, although there are a few differences.

I upgraded from Commons 3.x-dev to 3.3, rather than from 3.2. All the content types that came with Commons (groups, event, questions, etc.) have titles, but all the content types I've added myself are missing them. The titles don't show on admin/content, or when viewing the node, or editing the node. When re-adding the title, or adding new content, the title behaves normally.

But the missing titles aren't entirely gone. If I look in the node table in the database, the titles are there. They just aren't making it out of the DB in one piece.

I wonder if there was a title bug that was found between 3.2 and 3.3, but only fixed for Commons' content types, and not in a generic way. That's just conjecture, but it would explain the similar, but slightly different, behavior when upgrading from 3.x-dev to 3.3.

I'll see what I can dig up as a solution. At the very least, it's easier to edit nodes and paste in missing titles from the DB than it is to have to remember and retype the missing titles.

Status:Active» Postponed (maintainer needs more info)

@cstillwell To be clear, the title property for your custom content types has been replaced with a title field using the Title module?

@Devin Carlson, I believe so.

By "title property" you mean the pseudo-field that comes with every content type by default, with machine name "title"?

All of our pre-update custom content types are currently using what looks like a full-fledged field with machine name "title_field", and show up on admin/reports/fields as having that field, right next to the Commons content types. I'm guessing that comes from the Title module.

As an experiment, we just created a new content type, and it started out with the title pseudo-field. After managing the experimental content type and clicking the "replace" link next to the title, we do get the "title_field" field, and it shows up as expected on admin/reports/fields. But none of my colleagues nor I remember ever having clicked the replace link before.

I did not think to look in the DB, so I can't say if that was the same in my case or not.

At this point, I have gone ahead and recreated my original titles, so it's probably too late to help with debugging.

IS anyone else seeing issues of page manager variants disappearing?? (Should I file that as a separate issue?) These are much harder to recreate than the page titles and I really don't want to have to try to remember what all I had done before and then recreate them by hand. Is there a way I can look for my old variants? Could they be hiding in the database somewhere as well? Thanks for any suggestions.

Try disabling the Title module.

I encountered "missing" titles after upgrading from 3.3 to 3.4. they were in the database, but i think that something went wrong with commons_bw_update_7302 (#1969088: Changes to group browsing widget & user status updates). Disable title module (which i had never configured) seems to have fixed it.

Is there a solution to this problem yet? Disabling and re-enabling the module (many other modules depend on it) did not work for me and I have thousands of nodes without titles, making manual re-entry a non-option.

@bonobo_34, I just wound up recreating both my titles and my page manager variants by hand unfortunately, so I don't have any advice for you. I'm wondering if you look in your db, are the original titles in there, as described in comment #2? Did your titles disappear for all content types or did it depend on if it was a custom content type or not?

Honestly, the hassle this upgrade has been makes me nervous to think about going to 3.4 anytime soon.

The title were still in my database, this is the script I ended up writing to get them in the right place. Hopefully this helps someone.

<?php
$nodes
= array();
$untitled_nodes = array();
$con = mysqli_connect("'hostname', 'user', 'pass', 'db'");
$query = "SELECT * FROM node WHERE 1";
$result = mysqli_query($con, $query);
  if (!
$result)
    die(
'Invalid query: ' . mysqli_error($con));
  else
// The query was successful
 
{
    while(
$row = mysqli_fetch_assoc($result))
      {
       
$nid = $row['nid'];
       
$vid = $row['vid'];
       
$type = $row['type'];
       
$language = $row['language'];
       
$title = $row['title'];
       
$nodes[$nid] = array("nid" => $nid,
                            
"vid" => $vid,
                            
"type" => $type,
                            
"language" => $language,
                            
"title" => $title,);
      }
  }
$num_nodes = count($nodes);
echo
"There are ".$num_nodes." nodes total\r\n";
foreach(
$nodes as $nid=>$info)
{
  if(!
hasTitle($con, $nid))
   
$untitled_nodes[$nid] = $info;
}
echo
"There are ".count($untitled_nodes)." untitled nodes\r\n";
// Give back the titles to the untitled nodes
foreach($untitled_nodes as $nid=>$info)
{
  if(
addTitle($con, $info))
    echo
"Title ".$info['title']."\r\nAdded for node ".$nid."\r\n\r\n";
  else
    echo
"FAILED Title ".$info['title']."\r\nFAILED to add for node ".$nid."\r\n\r\n";
}
// change all node languages to 'und'
foreach($nodes as $nid=>$info)
{
  if(
changeLanguage($con, 'und', $nid, $info['vid']))
    echo
"nid:".$nid."updated\r\n\r\n";
  else
    echo
"nid:".$nid."FAILED\r\n\r\n";
}
function
addTitle($con, $info)
{
 
$q1 = false;
 
$q2 = false;
 
$entity_type = 'node';
 
$bundle = $info['type'];
 
$deleted = 0;
 
$entity_id = $info['nid'];
 
$revision_id = $info['vid'];
 
$language = $info['language'];
 
$delta = 0;
 
$title_field_value = addslashes($info['title']);
 
$query = "INSERT IGNORE INTO field_data_title_field(entity_type, bundle, deleted, entity_id, revision_id, language, delta, title_field_value) VALUES('$entity_type', '$bundle', $deleted, $entity_id, $revision_id, '$language', $delta, '$title_field_value')";
  echo
$query."\r\n\r\n";
 
$result = mysqli_query($con, $query);
  if (!
$result)
    die(
'Invalid query: ' . mysqli_error($con));
  else
// The query was successful
 
{
   
$q1 = true;
  }
  if(
$q1)
  {
   
$query = "INSERT INTO field_revision_title_field(entity_type, bundle, deleted, entity_id, revision_id, language, delta, title_field_value) VALUES('$entity_type', '$bundle', $deleted, $entity_id, $revision_id, '$language', $delta, '$title_field_value')";
    echo
$query."\r\n\r\n";
   
$result = mysqli_query($con, $query);
    if (!
$result)
    die(
'Invalid query: ' . mysqli_error($con));
    else
// The query was successful
   
{
   
$q2 = true;
    }
  }
  return
$q1 AND $q2;
}
function
hasTitle($con, $nid)
{
 
$q1 = false;
 
$q2 = false;
 
$query = "SELECT entity_id FROM field_data_title_field WHERE entity_id=$nid";
 
$result = mysqli_query($con, $query);
  if (!
$result)
    die(
'Invalid query: ' . mysqli_error($con));
  else
// The query was successful
 
{
    while(
$row = mysqli_fetch_assoc($result))
      {
        if(
$row['entity_id'])
         
$q1 = true;
      }
  }
  if(
$q1)
  {
   
$query = "SELECT entity_id FROM field_revision_title_field WHERE entity_id=$nid";
   
$result = mysqli_query($con, $query);
    if (!
$result)
      die(
'Invalid query: ' . mysqli_error($con));
    else
// The query was successful
   
{
      while(
$row = mysqli_fetch_assoc($result))
        {
          if(
$row['entity_id'])
           
$q2 = true;
        }
    }
  }
  return
$q1 AND $q2;
}
function
changeLanguage($con, $lang, $nid, $rid)
{
 
$q1 = false;
 
$q2 = false;
 
$q3 = false;
 
$query = "UPDATE node SET language='$lang' WHERE nid=$nid and vid=$rid";
 
$result = mysqli_query($con, $query);
  if (!
$result)
    die(
'Invalid query: ' . mysqli_error($con));
  else
// The query was successful
 
{
    echo
mysqli_affected_rows($con);
   
$q1 = true;
  }
  if(
$q1)
  {
    echo
" node was updated\r\n";
   
$query = "UPDATE field_data_title_field SET language='$lang' WHERE entity_id=$nid AND revision_id=$rid";
   
$result = mysqli_query($con, $query);
    if (!
$result)
      die(
'Invalid query: ' . mysqli_error($con));
    else
// The query was successful
   
{
      echo
mysqli_affected_rows($con);
     
$q2 = true;
    }
  }
  if(
$q1 AND $q2)
  {
    echo
" field_data_title_field was updated\r\n";
   
$query = "UPDATE field_revision_title_field SET language='$lang' WHERE entity_id=$nid AND revision_id=$rid";
   
$result = mysqli_query($con, $query);
    if (!
$result)
    die(
'Invalid query: ' . mysqli_error($con));
    else
// The query was successful
   
{
      echo
mysqli_affected_rows($con);
     
$q3 = true;
    }
  }
  if(
$q1 AND $q2 AND $q3)
  {
    echo
" field_revision_title_field was updated\r\n";
    return
true;
  }
}
?>

Issue summary:View changes
Status:Postponed (maintainer needs more info)» Active

setting back to active.

Wow @bonobo_34, that's great. wish I'd had that a month ago when all my titles disappeared. glad you found a way to retrieve the titles.

I think having a similar problem with Commerce Kickstart updates & the title module field kind of inadvertently eating the titles of products. See #2079497: Problems when upgrading from 2.7 -> 2.8 - Product titles go missing - I think a similar ball of wax, going to try modifying the script if I can narrow down the fields. Also here: #1813016: Page titles missing after reverting back to legacy entity field from regular field.