csv export/import uploads

By 4cdg - February 3, 2011

I am trying to move several cms into one cms. I have successfully exported table with csv export and sucessfully imported table with csv import except for the uploads.

I notice you can import into an upload table, but you cannot export from an upload table. Is there any easy way to get the images from one cms to another using these 2 plugins?

Re: [4cdg] csv export/import uploads

By Damon - February 4, 2011

Hi,

I notice you can import into an upload table, but you cannot export from an upload table. Is there any easy way to get the images from one cms to another using these 2 plugins?


The most straight forward way to get uploads table data from one CMS install into another would be to export the database then import into the new CMS install. Before you import, you would need to do a quick search and replace to update the uploads server file path in the mysql file.

In CMS Builder 2.07, there is also a new feature the that allows you to pick a specific table to backup so you could choose the uploads table.

The issue is that you are moving several cms's into one cms. The uploads are associated with a record based on the recordNum. It is going to be extremely difficult to match the uploads to the associated records as you have probably renumbered the associated records when you combined multiple CMS data.

If you can use the database export/import for the bulk of the uploads, that would be the best approach. Then manually match up the records in the database file.
Cheers,
Damon Edis - interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Damon] csv export/import uploads

By 4cdg - February 16, 2011

i have been unable to import to the uploads table.

I exported the table from on cms then did some manual manipulation to create a csv file.

I have gotten 2 different error messages. The first errored on every row, (790 something) and it read as follows

Import Row #1 - MySQL Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 32

this happened for every row and also listed all the columns and content under the error.

then i made some slight changes to the csv and got this error

There was an error sending the request! (200 OK) parsererror - Invalid JSON: No import filename!

I can send any additional info anyone needs to help.

Re: [Jason] csv export/import uploads

By 4cdg - February 18, 2011

i used a combination of both since you cannot export the uploads table with your csv export. I used the cms backup to get my uploads table data, and converted that file to csv. I had to remove things from the resulting backup file to get it in a useable format.

Once i saved this information in a csv format i used the cms import plugin to try to upload this information into another cms. That is when i got the resulting errors

Re: [4cdg] csv export/import uploads

By Jason - February 18, 2011

Hi,

When you create a backup file, CMS BUilder add a lot of information information that wouldn't work very well in a CSV format. I think the best solution would be to not use the CSV importer to move upload record between databases.

Try creating a backup file for your uploads table. Go through the file and change any file paths you need to. Next, move that file to your new CMS installation and put it in the backups folder. Finally, go through General Settings and restore the backup file.

NOTE: Make sure you do a complete backup of your new installations database before attempting a restore.

Hope this helps.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/