Joomla 3.9.12
XAMPP PHP 7.3
Phoca Cart Premiere Theme
Gantry 5.4.31
Joomlead Uikit3 and particles (subscribed)
Hi Jan
Problem Import and Export via CSV
Having some problems with the import of products using the Import function. I cannot seem to import any products now.
You were good enough to provide a CSV import file that you attached from here viewtopic.php?f=44&t=60235 and this worked fine.
I then created a new import file using my virtuemart data assigned to the Phoca Cart data columns, this is when the problem started.
The file will upload correctly and the import process appears to run to 100% and give a success message (progress bar stays on screen at 100% but system success message appears)
Then, all products in the Phoca Cart admin Product List have disappeared. SO then tested the export.
File was exported with products present in CSV! But no products viewable in Phoca Cart
So then tried to import original data again (to overwrite) and process completes just fine but still no products.
There are no javascript errors when testing with Chrome Developer and I have tried the process with UIkit3 from Joomlead turned on and off.
Also, noticed that the CSV column headers don't always match the data in the columns. Even in the original CSV you were good enough to send me.
For example, headers and data match ok up until column AE - header row 1 type_category_feed, row 2 Product Category Type (XML Feed) suggest column data should contain xml data, but instead there is product long description data in columns!
Description columns contains image url data and so on until column AN when Stock header and data values appears to synchronise again.
I have tried csv files using MS Excel and Open Office
Also, import files appear to have semi colon delimiters - ;
But when exporting from Phoca Cart, files appear to be comma delimited - ,
Confused! Any ideas on how to fix this or what I am doing wrong? I can move site onto development server if you want to see the problem
Regards
David
Import and Export Problem
- Jan
- Phoca Hero
- Posts: 48403
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Import and Export Problem
Hi,
1) are you sure, the export from Phoca Cart uses commas. The setting is semi colon ;
but you can see JSON inside the CSV which uses comma:
But items outside JSON just use semi colon ;
When you see your administration, no products are listed there? (after import)
When you e.g. delete all data and you will do import of the example CSV, still no products?
Jan
1) are you sure, the export from Phoca Cart uses commas. The setting is semi colon ;
but you can see JSON inside the CSV which uses comma:
Code: Select all
[{""id"":""1:alias"",""ordering"":""1""}]
When you see your administration, no products are listed there? (after import)
When you e.g. delete all data and you will do import of the example CSV, still no products?
Jan
If you find Phoca extensions useful, please support the project
- dmlwebal
- Phoca Professional
- Posts: 238
- Joined: 18 Sep 2019, 12:49
Re: Import and Export Problem
Hi Jan,
Thank you for the reply.
First of all, my apologies, the output is semicolon ';' delimiter
Now using LibreOffice Calc with ; delimiter and " for text entries. My output is utf-8
When I import the data from the csv, upload and install progresses as normal. But no products in Phoca Cart admin!
After some efforts I managed to partially import two products and after lloking more closelty at my column data I think that my csv has some hidden values and the lines are breaking . For example, long descriptions introduce a line break, this may be happening throughout various fields in my CSV so I must check it carefully.
The only way to introduce products is manually (over 500!) with all product attributes which takes a long time and is boring!
To successfully import using CSV which columns must have data in them? Can any be blank, like Categories, Manufacturer and Group? Or must they all contain data?
I ask because the formatting in these columns in the CSV is not easy to generate and it would be better for me to assign this information from the Phoca Product Admin after the rest of the product data is imported.
Not familiar with JSON, ok with XML and other formats but never got around to learning JSON :shock:
Regards
David
Thank you for the reply.
First of all, my apologies, the output is semicolon ';' delimiter
Now using LibreOffice Calc with ; delimiter and " for text entries. My output is utf-8
When I import the data from the csv, upload and install progresses as normal. But no products in Phoca Cart admin!
After some efforts I managed to partially import two products and after lloking more closelty at my column data I think that my csv has some hidden values and the lines are breaking . For example, long descriptions introduce a line break, this may be happening throughout various fields in my CSV so I must check it carefully.
The only way to introduce products is manually (over 500!) with all product attributes which takes a long time and is boring!
To successfully import using CSV which columns must have data in them? Can any be blank, like Categories, Manufacturer and Group? Or must they all contain data?
I ask because the formatting in these columns in the CSV is not easy to generate and it would be better for me to assign this information from the Phoca Product Admin after the rest of the product data is imported.
Not familiar with JSON, ok with XML and other formats but never got around to learning JSON :shock:
Regards
David
- dmlwebal
- Phoca Professional
- Posts: 238
- Joined: 18 Sep 2019, 12:49
Re: Import and Export Problem
UPDATE - I see the problem now. When I add products manually then EXPORT the CSV and read it in notepad++ there is a difference. The difference is that the Phoca output CSV has contained each field within " " quote marks
When I try to generate my CSV using a template based on a Phoca export file the quotes " are missing so data is not imported properly. Understandable because formatting is wrong!
So now just need to be able to paste data into a new Phoca import CSV file but make sure quotes are included properly on export. Not sure how to do this!
It must be related to edit filters on output but I don't know how to set them up correctly to match the format Phoca Cart needs.
Regards
David
When I try to generate my CSV using a template based on a Phoca export file the quotes " are missing so data is not imported properly. Understandable because formatting is wrong!
So now just need to be able to paste data into a new Phoca import CSV file but make sure quotes are included properly on export. Not sure how to do this!
It must be related to edit filters on output but I don't know how to set them up correctly to match the format Phoca Cart needs.
Regards
David
- dmlwebal
- Phoca Professional
- Posts: 238
- Joined: 18 Sep 2019, 12:49
Re: Import and Export Problem - SOLVED
Hi,
Figured out the problem by importing the CSV into Notepad++ column by column to strip out the hidden values that were introduced by MS Excel. Then imported the data into LibreOffice Calc (some cut and paste) and the result was much better. Now only need to assign categories and manufacturers.
Figured out the problem by importing the CSV into Notepad++ column by column to strip out the hidden values that were introduced by MS Excel. Then imported the data into LibreOffice Calc (some cut and paste) and the result was much better. Now only need to assign categories and manufacturers.
- Jan
- Phoca Hero
- Posts: 48403
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact: