We're in the process of figuring out quite how much work upgrading to Drupal 7 is going to be. The thing that is really worrying me, is that we currently have our main content as Nodes:

Equipment
Person
Company
Address
Contract
Timesheet
Now, these are linked together using join tables (timesheet for person, address for company, etc) using the node ids, obviously.

Anyway, the possibility of exporting all of this information somehow seems impossible to me. The only way we can possibly do it is to be able to import Nodes into the new format and preserve the current Node IDs, or entity IDs in Drupal 7

Is this possible?

Comments

WorldFallz’s picture

yowsa-- you might want to consider taking the opportunity to redefine these relationships in a drupal way, or you'll just face the same problem over and over again.

In any case, if you do an upgrade-- you'll keep the same node ids. Otherwise maybe checkout the migrate module and see if this something that was considered over there.

mykmallett’s picture

Thanks for your response.

I can't really think of a way to have a many to many relationship in the database without join tables? I'll be very surprised if this isn't something that has occurred before. Preserving primary key relationships is surely one of the most important factors when migrating data.

I've looked into the migrate module and I think it might preserve Node ids (or turn them into entity IDs) which would be perfect, however I can;'t seem to get confirmation on this. Anyone know for sure? I saw that when migrating Users it preserves UID, but not mention of NID

I would prefer to do a clean install and migrate, as it will give the opportunity for us to clean house a bit. But the majority of our CCK nodes are simple text fields, is the upgrade process for CCK fields error prone?

WorldFallz’s picture

Relationships between drupal entities are typically handled via references, entityreference, or relation modules and those are the cases supported by modules like feeds and migrate. Mixing drupal methodology with direct db manipulation is what puts you in no man's land.

mykmallett’s picture

I'm not too keen on using the drupal methodology when I don't have to, the overhead is ludicrous. Using references are impossible for our use case.

Anyway, the migrate module does what I need it to do, thanks.

WorldFallz’s picture

awesome! and that's good to know... thanks for posting back.