---
title: "Is there any recommended steps to migrate sqlite data to postgresql"
url: "https://openforis.support/questions/3368/is-there-any-recommended-steps-to-migrate-sqlite-data-to-postgresql"
tags: ["collect"]
status: "answered"
score: 0
answer_count: 2
asked: "2022-04-06T03:15:33"
last_activity: "2022-06-08T10:20:25"
source: "Open Foris Support - Q&A Forum"
license: "Copyright Open Foris, 2026. Some rights reserved under creative commons license."
---

# Is there any recommended steps to migrate sqlite data to postgresql

Asked by simiti on 2022-04-06

I recently installed Collect in a multi user environment using postgresql. I have old data in my Standalone Collect environment. What is a recommended steps to migrate sqlite data to postgresql?

Thanks
Smith


## Answer (score 0, by Stefano (OF) on 2022-04-06)

Link: https://openforis.support/questions/3368/is-there-any-recommended-steps-to-migrate-sqlite-data-to-postgresql/3369

Dear Smith,  
You have 2 options:  

 1. take a complete backup of survey(s) and data from the Backup / Restore module in Collect and restore the backup in the new installation of Collect, the one using PostgreSQL
 2. export the content of the database from SQLite to SQL, using for example a software like SQLite browser, that is free, modify the generated SQL and try to restore it into PostgreSQL; the structure of databases is similar, you shouldn't have big issues (skip the part of the database/schema/tables generation while restoring it).  

We suggest you to use the first option, that is probably faster.  
Let us know, many thanks.  
Open Foris Team

> I managed to migrate the data from SQlite to PostgreSQL but it throws out error. I still cannot get it to work. (simiti)
> Dear Smith, please try to migrate only the data to the PostgreSQL database. First of all configure Collect to work with a new PostgreSQL database, start it up and let it create an empty schema into it. Then export only the data from the SQLite database and import it into the tables of the PostgreSQL database. We will contact you to your private email address to try to help you with this. (Stefano (OF))

## Answer (score 0, by Stefano (OF) on 2022-06-08)

Link: https://openforis.support/questions/3368/is-there-any-recommended-steps-to-migrate-sqlite-data-to-postgresql/3408

Dear Smith,  
If you have a small number of surveys in your installation of Collect, the easiest thing would be to take a Backup of each survey and Restore it in the new installation of Collect.  
You can easily do it from the Backup/Restore module in the application.  
Many thanks,  
Open Foris Team
