Jump to content

Restore Database Catalogue


platedepot

Recommended Posts

I accidentally destroyed my product catalog while doing some maintenance (over 2000 products). I did backup the database before doing this, and I am now unsure of how to restore it. The rest of the database is intact, but since I have a full backup, it would probably be best just to restore everything.

Can anyone help me with the restoration process?

Thanks

MARK

Link to comment
Share on other sites

To quickly go over what I think I would do is:

1. The backup probably made a SQL script that when run, would rebuild the database.

2. I do not recall if there is a companion Restore function in CC4 alongside the Backup function.

3. If not, then access your database via phpMyAdmin (available through your hosted account's control panel).

4. (Optional) Extract just that part of the script that builds the _inventory table.

5. Feed the script to phpMyAdmin.

or

Contact your hosting provider. They could very well be able to restore just that table from their backups.

Link to comment
Share on other sites

To quickly go over what I think I would do is:

1. The backup probably made a SQL script that when run, would rebuild the database.

2. I do not recall if there is a companion Restore function in CC4 alongside the Backup function.

3. If not, then access your database via phpMyAdmin (available through your hosted account's control panel).

4. (Optional) Extract just that part of the script that builds the _inventory table.

5. Feed the script to phpMyAdmin.

or

Contact your hosting provider. They could very well be able to restore just that table from their backups.

How do you extract just one table out of an SQL backup file?

Link to comment
Share on other sites

In my opinion, as not having an actual CC4 store up and running, the database backup function will tell the database server to examine all the tables and data in the tables and from that create a SQL script that, when fed back to a database server, will re-create the tables and populate them with the data. SQL scripts are plain text files.

The script will have the requisite commands to recreate the database "schema". If you have the CubeCart install package, you can look at the setup scripts used to create the initial schema for an "empty" store but loaded with currencies, countries, and one sample product. The backup script will look very much like that.

Even though it is one script file, within it are the commands to create each table in turn and populate that table. Therefore, as the script isa plain text file, one can copy/paste just the script part that CREATEs a TABLE for just the table you want, followed by the series of INSERT statements for the data to be put in that table, to a new file.

Then feed this new file to the database server using your favorite database management client: phpMySQL or MySQL Workbench.

Link to comment
Share on other sites

In my opinion, as not having an actual CC4 store up and running, the database backup function will tell the database server to examine all the tables and data in the tables and from that create a SQL script that, when fed back to a database server, will re-create the tables and populate them with the data. SQL scripts are plain text files.

The script will have the requisite commands to recreate the database "schema". If you have the CubeCart install package, you can look at the setup scripts used to create the initial schema for an "empty" store but loaded with currencies, countries, and one sample product. The backup script will look very much like that.

Even though it is one script file, within it are the commands to create each table in turn and populate that table. Therefore, as the script isa plain text file, one can copy/paste just the script part that CREATEs a TABLE for just the table you want, followed by the series of INSERT statements for the data to be put in that table, to a new file.

Then feed this new file to the database server using your favorite database management client: phpMySQL or MySQL Workbench.

LOL! I'm sure that will help somebody, but that won't be me. I'm much to much a Novice to try anything like that. Thanks for trying, though. :unsure:

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...