# Data Migration Queries

**URL:** <https://community.hubspot.com/t/data-migration-queries/124435>\
**Category:** CRM\
**Tags:** crm\
**Created:** [January 21, 2025, 11:37am UTC](https://community.hubspot.com/t/data-migration-queries/124435 "2025-01-21T11:37:04Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![PBarik8](https://avatars.discourse-cdn.com/v4/letter/p/9d8465/32.png) [@PBarik8](https://community.hubspot.com/u/PBarik8)\
**Post date:** [January 21, 2025, 11:37am UTC](https://community.hubspot.com/t/data-migration-queries/124435/1 "2025-01-21T11:37:04Z")

</div>

I want to migrate data from “A” account to “B” account. Below are the data to be migrated;

1. Deals

2. Contacts

3. Companies

4. Users

5. Tasks

For users, I want to import all the associated records as well. While I was exporting data from “User and Teams”, the associated records were not exported.

1. Do I need to separtely export records for each like Contacts, Tasks, etc.. separately, OR is there a way to export all of them?

2. If there’s a deactive user, however the deals are open - will the deactivated users be migrated or there are chances we lose the deals if we don’t migrate them? What is the best possible solution to this?

---

<div class="post-metadata">

**Author:** ![karstenkoehler](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/karstenkoehler/32/68554_2.png) [@karstenkoehler](https://community.hubspot.com/u/karstenkoehler)\
**Post date:** [January 21, 2025, 11:55am UTC](https://community.hubspot.com/t/data-migration-queries/124435/2 "2025-01-21T11:55:05Z")

</div>

Hi @PBarik8,

Unless you use third party tools (like Portal to portal migrator), you’ll have to export each object’s records separately – and from experience, reimporting with the correctly established associations is challenging. The main challenge is that you’ll need repeated imports to establish all associations but want to avoid duplicates, which requires exporting records in between imports, to get their record IDs. I won’t sugarcoat it, it’s a frustrating process.

To your second question, exports will include deal records assigned to deactivated users. No need to take additional steps.

Best regards

---

<div class="post-metadata">

**Author:** ![PBarik8](https://avatars.discourse-cdn.com/v4/letter/p/9d8465/32.png) [@PBarik8](https://community.hubspot.com/u/PBarik8)\
**Post date:** [January 21, 2025, 12:12pm UTC](https://community.hubspot.com/t/data-migration-queries/124435/3 "2025-01-21T12:12:36Z")

</div>

Is it possible to migrate all the objects at once in a sheet?

Like one excel sheet with different tabs of each object data, will it be possible to import?

Also, the exports will include deal records associated to deactivated users. What if we are not improting the deactivated user, will the records still migrate?

---

<div class="post-metadata">

**Author:** ![karstenkoehler](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/karstenkoehler/32/68554_2.png) [@karstenkoehler](https://community.hubspot.com/u/karstenkoehler)\
**Post date:** [January 21, 2025, 12:38pm UTC](https://community.hubspot.com/t/data-migration-queries/124435/4 "2025-01-21T12:38:42Z")

</div>

@PBarik8 no, a one file solution does not exist.

If you’re not ‘migrating’ a user, that will at the most generate an error during the import, the record will however be imported, simply missing its owner.

---

<div class="post-metadata">

**Author:** ![PBarik8](https://avatars.discourse-cdn.com/v4/letter/p/9d8465/32.png) [@PBarik8](https://community.hubspot.com/u/PBarik8)\
**Post date:** [January 21, 2025, 2:17pm UTC](https://community.hubspot.com/t/data-migration-queries/124435/5 "2025-01-21T14:17:14Z")

</div>

If I migrate the contacts or companies, will the activities also be migrated automatically or do I need to follow some other steps?

---

<div class="post-metadata">

**Author:** ![karstenkoehler](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/karstenkoehler/32/68554_2.png) [@karstenkoehler](https://community.hubspot.com/u/karstenkoehler)\
**Post date:** [January 21, 2025, 2:19pm UTC](https://community.hubspot.com/t/data-migration-queries/124435/6 "2025-01-21T14:19:52Z")

</div>

@PBarik8 activities can currently not be exported directly. You can create custom reports and export those reports, but there’s no direct export option. (That’s one of the reasons why solutions like this one exist: [HubSpot Marketplace](https://ecosystem.hubspot.com/marketplace/apps/hubspot-to-hubspot-migration))
