Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Import/Export in version 0.8.16100
 
zadpro
Sr. Member
 
Avatar
Total Posts:  247
Joined:  2007-12-10
FL, USA
 

I used version 7 and the import/export was working just fine. However, after I installed (fresh install) of the new version (0.8.16100) I get wiered data file.
When I export as a csv either tab or comma, and I open the file in excel, everything is missed up and disorganized.
When I export as XML and try to open it in excel, I get an error that the file is curropted. (I was able to open the xml from version 7 in excel and worked perfectly).

Anybody has this problem? I have attached both CSVs and xml files that I have exported from my sample store to this email.
Any idea?

File Attachments
test.zip  (File Size: 71KB - Downloads: 183)
 
Magento Community Magento Community
Magento Community
Magento Community
 
zadpro
Sr. Member
 
Avatar
Total Posts:  247
Joined:  2007-12-10
FL, USA
 

Any body has any idea or is this happening to anyone else?

 
Magento Community Magento Community
Magento Community
Magento Community
 
JoshBelke
Member
 
Total Posts:  64
Joined:  2008-02-12
NY, NY
 

Im guessing many haven’t tried importing/exporting.

For now (in reference to the other article you were writing in),

I am running into export issues with the all too famous “Invalid option id specified for custom_desigin(), skipping the record for all product set types.

This is with the default null value on every product, (i dont recall it being needed required*)

My export (CSV) looks like:
josh@world: cat test_m6_2

"store","attribute_set","type","entity_id","sku","status","visibility","name","url_key","meta_title","meta_description","image","gift_message_available","small_image","thumbnail","meta_keyword","custom_layout_update","weight","short_description","description"
"base"
,"modules","Grouped Product","17","n01860-423","Enabled","Catalog, Search","n01860-423","n01860-423","","","/n/0/n01860-423.jpg","Use config","/n/0/n01860-423_1.jpg","/n/0/n01860-423_2.jpg","","","","",""

XML looks like:
cat test_m6_2

<?xml version="1.0"?><?mso-application progid="Excel.Sheet"?>
<Workbook xmlns:x="urn:schemas-microsoft-com:office:excel"
  
xmlns="urn:schemas-microsoft-com:office:spreadsheet"
  
xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"><Worksheet ss:Name="test_m6_1_xml"><ss:Table><ss:Row><ss:Cell><Data ss:Type="String">store</Data></ss:Cell><ss:Cell><Data ss:Type="String">attribute_set</Data></ss:Cell><ss:Cell><Data ss:Type="String">type</Data></ss:Cell><ss:Cell><Data ss:Type="String">entity_id</Data></ss:Cell><ss:Cell><Data ss:Type="String">sku</Data></ss:Cell><ss:Cell><Data ss:Type="String">status</Data></ss:Cell><ss:Cell><Data ss:Type="String">visibility</Data></ss:Cell><ss:Cell><Data ss:Type="String">name</Data></ss:Cell><ss:Cell><Data ss:Type="String">url_key</Data></ss:Cell><ss:Cell><Data ss:Type="String">meta_title</Data></ss:Cell><ss:Cell><Data ss:Type="String">meta_description</Data></ss:Cell><ss:Cell><Data ss:Type="String">image</Data></ss:Cell><ss:Cell><Data
 
Magento Community Magento Community
Magento Community
Magento Community
 
Mark_Kimsal
Sr. Member
 
Total Posts:  186
Joined:  2007-09-12
Michigan, USA
 

You CSV doesn’t work because Magento does not make correct CSV exports.  I filed a bug about 3-4 months ago.  Not only does it use a non-standard escape character, it doesn’t even do what it wants to do correctly.  It escapes things in the wrong order, that’s why your CSV files end up with double backslashes in front of quotes \\”.  This completely invalidates trying to use backslashes to escape quotes in the first place!  I guess I’m the only person using import/export properly.  I just assumed they fixed it back in November.

lib/Varien/Convert/Parser/Csv.php line 135change
$fEsc 
$this->getVar('escape''\\');
into
$fEsc 
$this->getVar('escape''"');

change line 149
                $line[] 
$fEnc.str_replace(array('"''\\'), array($fEsc.'"'$fEsc.'\\'), $f).$fEnc;
to
                $line[] 
$fEnc.str_replace(array('"'), array($fEsc.'"'), $f).$fEnc;

Similarly for line 162

$v 
= isset($row[$f]) ? str_replace(array('"'), array($fEsc.'"'), $row[$f]) : '';

Now your CSV can be opened by any proper CSV reader.

I have no clue why your MS-XML doesn’t work.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Armen
Member
 
Total Posts:  46
Joined:  2008-05-06
Los Angeles
 

Are you kidding me??? I’m on Magento 1.2.1 and this bug is still there. I have imported and exported my products several times while setting up my store, each time adding attributes and improving the categorization and description of them. All of a sudden my CSV files refuse to open in OpenOffice and its because I have an excessive amount of double quote marks all over the place in my product descriptions.

What am I supposed to do with this now? How can I recover from this? This is nuts. How could they have not fixed this bug yet??? Really quite shocking.

Did anyone file a bug on this? Is it still open? Did they respond to it?

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top