Was hoping that the UI would allow me to migrate crom content profile fields (which is does) to profile 2 fields (which it doesn't as far as I can tell) - they don't come up in the destination fields. I can migrate from content profile fields to user fields, but I was really hoping to use profile 2 for it's separate user profiles (roles) sign up wizardry. Am I missing something or is this really not possible. If not it would be great if it could be made to. I think (a while ago) I found a post suggesting that it was possible using migrate but not with the UI - but I can't find that now.

CommentFileSizeAuthor
#1 migrate_d2d UI.png58.57 KBbisonbleu

Comments

bisonbleu’s picture

Version: 7.x-2.1-beta1 » 7.x-2.x-dev
StatusFileSize
new58.57 KB

I have the same issue and strongly second this request.

I've long looked for a migrate_d2d way of importing Drupal 6 content_profile fields into Drupal 7 profile2 fields. No luck yet and/or I can't figure it out.

Is there a way to do this through the migrate_d2d UI ?

Here are a few interesting references. #1 has the most details but it requires that you create a csv file with all the required data as well as a module. I can already import Users and Roles with migrate_d2d. Would be nice to just extend this to include content_profile to profile2 migration. #2 seems related; still investigating.

  1. Cookbook - Import new users and their Profile2 fields from one CSV file
  2. content_profile support - migrate profile node title
  3. Migrating content profiles to Profile2 using VBO
  4. Simple Drupal 6 to 7 User migration
  5. How to migrate D6 profile fields to D7 Profile2 directly
iaminawe’s picture

I am also interested in being able to do the content profile to profile2 migration process by extending the existing d2d classes to allow the profile types and fields to show up as destination fields to map the source fields from the d6 site to in the ui

I think as per the instructions here https://www.drupal.org/node/1819738 we would be looking to extend the existing Drupal 6 User migration class and then we would be including the content profile table in our query but this is as far as I have managed to get

<?php
class ExampleUserMigration extends DrupalUser6Migration {
  protected function query() {
    // Get the default query (all rows in the users table other than uid 1)
    $query = parent::query();
    // Exclude test accounts
    $query->condition('name', 'test-%', 'LIKE');
    // Add fields from a custom table
    $query->innerJoin('content_type_profile', 'd', 'u.uid=d.uid');
    $query->fields('d', array('field_firstname_value', 'field_lastname_value'));
    return $query;
  }
}
?>

I would be interested to hear @bisonbleu if you ever made any further progress with this

Thanks

bisonbleu’s picture

Hey @iaminawe,

Looking back at my notes from a year ago, here's what I think I ended up doing.

I gave up looking for a one-pass fully automated solution and went the Migrate way.

I first exported D6 content profile data to a .csv file (using views_data_export) and manually added a column with the matching D7 UIDs; users & roles which I had migrated earlier.

Then I created a custom module (based on the excellent Cookbook referenced in #1) with which to import my .csv file with Migrate (admin/content/migrate/).

So, a little more convoluted, but in the end it all worked out.

iaminawe’s picture

Thanks for responding with what worked for you - that approach looked comprehensive and I have not attempted it yet as I was hoping to avoid going through the csv export step as well as also avoiding the need for a second user migration to be run (aside from the ui one)

I thought using the d2d ui was still using the "migrate" way but with a bit of a head start on doing it all in a custom module

Ideally I thought we would be able to extend the users import class thats part of the ui using the custom module to then allow different profile entity fields to be targeted as destinations in the mapping interface.

I still think this would be a valuable feature to add to the d2d ui but it looks like for now I may need to go the csv and cookbook route

Thanks again

mikeryan’s picture

Are you using migrate_extras? It provides a destination handler for profile2.

roball’s picture

Title: Migration from content profile to profile 2 » Migration from D6 Content Profile to D7 Profile 2 fields
Component: User interface » D6-specific

Wouldn't it be better to move support for Profile 2 destination fields away from the Migrate Extras into the Drupal-to-Drupal data migration module? The latter already supports D6 Content Profile source fields, and Profile 2 fields are the successor of those fields in D7.

rcodina’s picture

I agree with @roball

zythyr’s picture

I am trying to migrate Content Profile fields in D6 to Profile2 fields in D7 using Migrate D2D UI. I am able to see the Content Profile fields (source) but I am unable to see any Profile2 fields in the destination for mapping.

I also tried to enabled the migrate_extras module, but I am still not seeing the Profile2 fields for destinations in the Migrate D2D UI.

Please add support in Migrate D2D UI for mapping into Profile2 fields into destination. I would love to have this feature!

aitala’s picture

Same problem as @Zythyr in #8...

Eric