# Export DB into another baserow account!

**URL:** https://community.baserow.io/t/export-db-into-another-baserow-account/3583
**Category:** Technical Help
**Created:** [October 13, 2023, 3:52pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583 "2023-10-13T15:52:41Z")
**Posts on this page:** 16
**Page:** 1

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [October 13, 2023, 3:52pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/1 "2023-10-13T15:52:41Z")

</div>

Dear Baserow users and fans,

I’m migrating from Baserow installed manually on a Debian to a Baserow installed using Docker compose. Both run on different machines.

How do I safely get one of my databases with all the PDF files from the manual version of the Baserow to a Docker-based version of Baserow on the other machine?

There is no “Export DB” feature in the UI. And those table exports don’t really export the whole setup.

---

<div class="post-metadata">

### Author: ![olgatrykush](https://community.baserow.io/user_avatar/community.baserow.io/olgatrykush/32/219_2.png) [@olgatrykush](https://community.baserow.io/u/olgatrykush)
#### Post date: [October 16, 2023, 8:59am UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/2 "2023-10-16T08:59:00Z")

</div>

Hello, @taubers, have you seen this thread: [Export/import database - #2 by petrs](https://community.baserow.io/t/export-import-database/1272/2)?

---

<div class="post-metadata">

### Author: ![petrs](https://community.baserow.io/user_avatar/community.baserow.io/petrs/32/159_2.png) [@petrs](https://community.baserow.io/u/petrs)
#### Post date: [October 16, 2023, 2:41pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/3 "2023-10-16T14:41:36Z")

</div>

Probably good to add that the files themselves are not stored in the database. So if you are going to use the same storage, the db migration is enough (for the file names etc.). Otherwise you will need to copy the files between the storage buckets.

---

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [October 16, 2023, 4:37pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/4 "2023-10-16T16:37:45Z")

</div>

Hi, Olga!

Thank you very much for your message!

Yes, I’ve seen it, but it also isn’t that helpful due to the lack of the Workspace ID and other open questions.

And also it does not say, where the export is saved. It also seems that there is no “export\_workspace\_applications” function in my baserow:

 ![image](https://community.baserow.io/uploads/default/original/2X/0/0a26112027dfa8c9ca007aa66205265673c07736.jpeg)

---

<div class="post-metadata">

### Author: ![olgatrykush](https://community.baserow.io/user_avatar/community.baserow.io/olgatrykush/32/219_2.png) [@olgatrykush](https://community.baserow.io/u/olgatrykush)
#### Post date: [October 16, 2023, 7:51pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/5 "2023-10-16T19:51:54Z")

</div>

Sure, I just wanted to make sure. 🙂

@petrs, maybe you could help out @taubers here please?

---

<div class="post-metadata">

### Author: ![petrs](https://community.baserow.io/user_avatar/community.baserow.io/petrs/32/159_2.png) [@petrs](https://community.baserow.io/u/petrs)
#### Post date: [October 17, 2023, 7:40am UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/6 "2023-10-17T07:40:20Z")

</div>

> [@taubers](#):
>
> export\_workspace\_applications

The image is cut off, why do you think the command is not there? It will save the file in the working directory from the perspective of the admin command. You can find the source for the command here: [backend/src/baserow/core/management/commands/export\_workspace\_applications.py · develop · Baserow / baserow · GitLab](https://gitlab.com/baserow/baserow/-/blob/develop/backend/src/baserow/core/management/commands/export_workspace_applications.py?ref_type=heads)

---

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [October 17, 2023, 10:10am UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/7 "2023-10-17T10:10:07Z")

</div>

I still don’t see it:

 ![image](https://community.baserow.io/uploads/default/original/2X/8/862a60ad68f55fbadca197804405cef893e25f2b.png)

But do you mean I should drag the source .py file into this directory and run it?

And - how to do I find the right Workspace ID?

And - “Otherwise you will need to copy the files between the storage buckets” - do you mean media folder files should be moved from one instance to another?

---

<div class="post-metadata">

### Author: ![petrs](https://community.baserow.io/user_avatar/community.baserow.io/petrs/32/159_2.png) [@petrs](https://community.baserow.io/u/petrs)
#### Post date: [October 18, 2023, 7:53am UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/8 "2023-10-18T07:53:46Z")

</div>

It seems that you are on some old version where the command is called `export_group_applications`. It is exactly the same command, only we were renaming groups to workspaces. Sorry for the confusion!

You can also forget about this serialized JSON representation and just transfer the Postgres database instead if the commands here give you trouble.

---

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [October 18, 2023, 10:17am UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/9 "2023-10-18T10:17:03Z")

</div>

Ok, so, what do you suggest to do with the files, since as you say “files themselves are not stored in the database”. I want to transfer both the workspaces with it’s entries and the files that were attached to the individual rows.

---

<div class="post-metadata">

### Author: ![petrs](https://community.baserow.io/user_avatar/community.baserow.io/petrs/32/159_2.png) [@petrs](https://community.baserow.io/u/petrs)
#### Post date: [October 18, 2023, 2:37pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/10 "2023-10-18T14:37:08Z")

</div>

The files are in the storage that you configured for your instance. So if for example you used S3 before and plan to keep it, you wouldn’t need to do anything.

If your storage location changes, you will need to move them manually. From the docs:

> By default, Baserow will store these files on the file system at the location set by  
> the MEDIA\_ROOT environment variable, which is `/baserow/media` in our `baserow/backend`  
> image or `$DATA_DIR/media` for the `baserow/baserow` all-in-one image.

---

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [October 23, 2023, 2:31pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/11 "2023-10-23T14:31:09Z")

</div>

> [@petrs](#):
>
> By default, Baserow will store these files on the file system at the location set by  
> the MEDIA\_ROOT environment variable, which is `/baserow/media` in our `baserow/backend`  
> image or `$DATA_DIR/media` for the `baserow/baserow` all-in-one image.

The command `./baserow.sh backend-cmd manage export_group_applications 35` really seems to do something:

```auto

root@556184fde463:/# ./baserow.sh backend-cmd manage export_group_applications 35
 [STARTUP][2023-10-23 14:08:40] Using provided external postgres at host.docker.internal or the DATABASE_URL  
 [STARTUP][2023-10-23 14:08:40] Using embedded baserow redis as no REDIS_HOST or REDIS_URL provided.   
 [STARTUP][2023-10-23 14:08:40] Importing REDIS_PASSWORD secret from /baserow/data/.redispass  
root@556184fde463:/#

```

No output, and no errors.

But where and in what form do I access the data and how do I import into the new docker instance?

I see 2 directories in the baserow/media folder.

```auto
root@556184fde463:/# ls -la baserow/media            
total 96
drwxr-xr-x 4 root root 4096 Jan 25 2022 .
drwxr-xr-x 1 baserow_docker_user baserow_docker_group 4096 Oct 16 13:00 ..
drwxr-xr-x 5 root root 4096 Jan 25 2022 thumbnails
drwxr-xr-x 2 root root 77824 Jun 7 2022 user_files

```

Thumbnails contains just few directories:

```auto
root@556184fde463:/# ls -la baserow/media/thumbnails/
total 212
drwxr-xr-x 5 root root 4096 Jan 25 2022 .
drwxr-xr-x 4 root root 4096 Jan 25 2022 ..
drwxr-xr-x 2 root root 65536 Jun 7 2022 card_cover
drwxr-xr-x 2 root root 65536 Jun 7 2022 small
drwxr-xr-x 2 root root 65536 Jun 7 2022 tiny

```

while “user\_files” folder contains lots of documents like .png, .jpg images, .pdf, .docx files. One larger file does not contain extension though and ends with a **.**

`$DATA_DIR/media` contains slighlty different folder structure:

```auto
root@556184fde463:/# ls -la $DATA_DIR/media
total 104
drwxr-xr-x 6 baserow_docker_user baserow_docker_group 4096 Sep 20 2022 .
drwxr-xr-x 8 root root 4096 Aug 22 2022 ..
drwxr-xr-x 2 baserow_docker_user baserow_docker_group 4096 Oct 13 16:06 export_files
drwxr-xr-x 5 baserow_docker_user baserow_docker_group 4096 Aug 22 2022 thumbnails
drwxr-xr-x 3 baserow_docker_user baserow_docker_group 4096 Sep 7 2022 user_1
drwxr-xr-x 2 baserow_docker_user baserow_docker_group 81920 Aug 22 2022 user_files

```

So, I still confused as of where to look to see the exported directory and how to import it in order to have my workspace with all the columns, rows and files inside the new docker image.

---

<div class="post-metadata">

### Author: ![petrs](https://community.baserow.io/user_avatar/community.baserow.io/petrs/32/159_2.png) [@petrs](https://community.baserow.io/u/petrs)
#### Post date: [October 25, 2023, 3:31pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/12 "2023-10-25T15:31:21Z")

</div>

You said you are using docker compose? Can you give me the exact command? Perhaps I can try locally and give you precise instructions.

If you are doing the export I think no need to move the files themselves, that would be in case you were moving the database (because the files are not stored in the db).

---

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [October 25, 2023, 7:35pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/13 "2023-10-25T19:35:44Z")

</div>

Unfortunately I couldn’t wait any longer for a solution and ended up manually creating a workspace in the new instance, adding manually everything. Hope there will be something like “export Workspace”/“import Workspace” feature available in the future through the Dashboard.

---

<div class="post-metadata">

### Author: ![olgatrykush](https://community.baserow.io/user_avatar/community.baserow.io/olgatrykush/32/219_2.png) [@olgatrykush](https://community.baserow.io/u/olgatrykush)
#### Post date: [October 27, 2023, 7:20am UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/14 "2023-10-27T07:20:53Z")

</div>

Sorry for the inconvenience, @taubers! I’ve added the idea of having a feature for ‘export/import of a workspace’ to the list of discussions. 🙌

---

<div class="post-metadata">

### Author: ![olgatrykush](https://community.baserow.io/user_avatar/community.baserow.io/olgatrykush/32/219_2.png) [@olgatrykush](https://community.baserow.io/u/olgatrykush)
#### Post date: [November 9, 2023, 12:30pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/15 "2023-11-09T12:30:53Z")

</div>

Hello @taubers, after discussing it with the team, I can confirm that we plan to make it possible to import/export a workspace through a dashboard: [Export/import workspace (#2076) · Issues · Baserow / baserow · GitLab](https://gitlab.com/baserow/baserow/-/issues/2076).

---

<div class="post-metadata">

### Author: ![taubers](https://community.baserow.io/letter_avatar_proxy/v4/letter/t/919ad9/32.png) [@taubers](https://community.baserow.io/u/taubers)
#### Post date: [November 13, 2023, 6:28pm UTC](https://community.baserow.io/t/export-db-into-another-baserow-account/3583/16 "2023-11-13T18:28:05Z")

</div>

Thank you! That’s great news!
