Migrate SQLite to PostgreSQL with pgloader

I recently needed to change one of my Django apps from using SQLite to PostgreSQL. I thought it was going to be challenging to move the data from the SQLite database file to my PostgreSQL server, but it couldn't have been easier! ✨

After installing pgloader with a simple apt install pgloader command, I ran the following command to move the data:

• pgloader sqlite:///path/to/my/db.sqlite3 postgresql://username:password@host:port/db_name

Done! 🎉

There's a lot more that pgloader can do, and it's worth reading the docs, but my simple SQLite migration worked the first time and without drama. 🥳

添加评论
点赞收藏
点踩分享查看原文
评论
?
参与讨论