Title: Restore Orders via SQL
Last modified: June 9, 2022

---

# Restore Orders via SQL

 *  Resolved [saulllynas](https://wordpress.org/support/users/saulllynas/)
 * (@saulllynas)
 * [4 years ago](https://wordpress.org/support/topic/restore-orders-via-sql/)
 * Hello. I have an old SQL database backup of website where Learnpress was installed
   and used to assign lessons and now I have another website with the same Learnpress
   and lessons. I want to migrate all orders information from old DB to the new 
   DB, but when I import all records to _posts table, the information doesn’t appear
   in Learnpress->Orders. If I create an order manually in Learnpress->Orders and
   i.e. change it’s order id in SQL (table _posts), it becomes invisible in Learnpress-
   >Orders. If I revert changes – it becomes visible.
 * Man question – what tables should I migrate from old DB to new DB in order to
   see all orders in Learnpress->Orders?

Viewing 1 replies (of 1 total)

 *  Thread Starter [saulllynas](https://wordpress.org/support/users/saulllynas/)
 * (@saulllynas)
 * [3 years, 12 months ago](https://wordpress.org/support/topic/restore-orders-via-sql/#post-15730724)
 * Ok, after analyzing DB, orders information are stored in _postmeta, _posts and
   learnpress_order_items tables.
 * Case can be closed.

Viewing 1 replies (of 1 total)

The topic ‘Restore Orders via SQL’ is closed to new replies.

 * ![](https://ps.w.org/learnpress/assets/icon-256x256.gif?rev=3254420)
 * [LearnPress - WordPress LMS Plugin for Create and Sell Online Courses](https://wordpress.org/plugins/learnpress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/learnpress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/learnpress/)
 * [Active Topics](https://wordpress.org/support/plugin/learnpress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/learnpress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/learnpress/reviews/)

## Tags

 * [posts](https://wordpress.org/support/topic-tag/posts/)
 * [sql](https://wordpress.org/support/topic-tag/sql/)
 * [table](https://wordpress.org/support/topic-tag/table/)

 * 1 reply
 * 1 participant
 * Last reply from: [saulllynas](https://wordpress.org/support/users/saulllynas/)
 * Last activity: [3 years, 12 months ago](https://wordpress.org/support/topic/restore-orders-via-sql/#post-15730724)
 * Status: resolved