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

Page 1 of 7
Import/Export orders? 
 
ryazor
Jr. Member
 
Total Posts:  11
Joined:  2008-03-27
Berlin, Germany
 

Hello community,

I am really pleased about the first stable version 1.0 of Magento which was released few days ago. Immediately I had to install the new stable on our companys server to explore the official release. When I upgraded the previous installation I discovered the new DataFlow-Features and i have to confess, that I did not expected that advancement of it’s import- and export-functionalities.
My previous problems, when I tried to import products based on CVS-files are solved.

As I mentioned in my first topic I published here I am a webdeveloper. Unfortunately nobody had an expedient answer for my questions.

Now I have got a new question, I could imagine, somebody - especially the developers - can answer me.
Is there an opportunity to import and/or export the current orders? My target is to cronjob an export of orders e.g. every hour.
That export-file (maybe XML) will be parsed and interpreted by our webapplications to exchange orderdata between Magento <-> my “exchange-layer"-solution <-> ERP-Backend (e.g. MS Dynamics NAV).

I am looking forward to your suggestions.
Best regards,
R. El-Dajani

 
Magento Community Magento Community
Magento Community
Magento Community
 
peterw83
Member
 
Total Posts:  44
Joined:  2007-11-12
 

We too are interested in import export of order info.  We would be willing to join forces financially with others to help the development of this functionality or extension.

 
Magento Community Magento Community
Magento Community
Magento Community
 
adityak
Member
 
Total Posts:  63
Joined:  2008-02-10
India
 

Im also looking for such a feature.
My e-commerce site will send orders to an ERP for processing.
These orders will be sent in Excel or XML format.

Is Magento coming up with a feature to export current orders in XML format?

 
Magento Community Magento Community
Magento Community
Magento Community
 
ZDOG
Jr. Member
 
Total Posts:  7
Joined:  2008-04-22
 

Count us in with this as well.

We process export orders and process via SAP Business One and another client wants to use Magento with MAS90.

 
Magento Community Magento Community
Magento Community
Magento Community
 
katiek648
Member
 
Total Posts:  33
Joined:  2008-04-10
 

We are also looking for this functionality. Has anyone successfully created this type of functionality? We have contacted a number of Magento partners, but they all seem to be very busy with projects. Just wondering if anyone has had any luck getting this set up

 
Magento Community Magento Community
Magento Community
Magento Community
 
Punani
Sr. Member
 
Total Posts:  76
Joined:  2008-02-12
 

same here!! we are working with Exact Globe 2003 (backend) and Exact e-Synergy (web based frontend) as our ERP system (SQL database)

we would like to use Magento as our e-commerce shop linked with Exact.

off course we are capable of joining forces (financially and technically) with others

greetings

Ivan

 
Magento Community Magento Community
Magento Community
Magento Community
 
nicolas46
Sr. Member
 
Total Posts:  210
Joined:  2008-04-09
Toulouse
 

I’m only a trainee and in 2 days I almost succeed to export order

My method is bad, it’s taking a long time to export and there is some mistake in the result. My method is very bad because I modified Varien class (Varien_Data_Collection) and I modified directly in core files, but I think that if you have the finance and the human resource it will be easy to develop a module. Unlikely I haven’t time to do so.

I modified _prepareCollection() in Mage_Adminhtml_Block_Sales_Order_Grid and _prepareColumns() to have some product attribute (I repeat order for each product which is in it). Because I want all the product of all my order I had to modify also Varien_Data_Collection to be able to add item with the same id and finally i use the function getCvs()on the grid.

File Attachments
commande.txt  (File Size: 6KB - Downloads: 1356)
 
Magento Community Magento Community
Magento Community
Magento Community
 
Andrey666
Member
 
Total Posts:  58
Joined:  2008-04-16
 

why dont u access magento database directly and with some sql sripts copy order data to your erp system database? no need to program anything but few scritps run by cron (script can export from magento database, process it, import to desired database)
this is what i am going to do…

 
Magento Community Magento Community
Magento Community
Magento Community
 
nicolas46
Sr. Member
 
Total Posts:  210
Joined:  2008-04-09
Toulouse
 

Yes, but want i want to export in a csv file.
Do you export all the order’s item attributes ?
It is not easy to export order and items attributes because of the database model. And if you write a script with some stuff like that : .

.. where attribute_id="245" and ....
Your script will work well with your version but maybe not with future version.
For all this reason i think it is better to use Magento class and write a php script with stuff like this :
$collectionCMD Mage::getResourceModel('sales/order_collection')        
                        ->
addAttributeToSelect('*');
...
  foreach (
$collectionCMD as $order)
                
//Récupération de tout les produits commandés sous forme d'items
                
$items$order->getItemsCollection();
.....
 
Magento Community Magento Community
Magento Community
Magento Community
 
alistek
Sr. Member
 
Total Posts:  293
Joined:  2008-04-02
Normal, IL
 

nicolas46 is right, it is much better to use the Magento way of exporting.  It actually isn’t that hard to export the order.  I have a few methods of sending the order out now.  The PHP|Architect book Guide to Programming with Magento by Mark Kismal has a REST system implemented.  It basically takes the code nicolas gave and formats it in XML.  You can then just navigate to a read/order and either give it a parameter or nothing and it will return the orders as XML.  Very effective and easy to code against.  I highly recommend it.

-Adam

 
Magento Community Magento Community
Magento Community
Magento Community
 
cibernoid
Sr. Member
 
Avatar
Total Posts:  208
Joined:  2008-02-12
 

@alistek: i have the PHP|Architect book aswell and I am trying to implement the example, but when I request the url

http://127.0.0.1/magento/index.php/adminrest/order/read

all I get is a blank page and this error message in the log:

2008-06-04T13:20:49+00:00 DEBUG (7): HEADERS ALREADY SENT
<
pre>
[0] C:\xampp\htdocs\magento\app\code\core\Mage\Core\Controller\Response\Http.php:44
[1] C
:\xampp\htdocs\magento\lib\Zend\Controller\Response\Abstract.php:727
[2] C
:\xampp\htdocs\magento\app\code\core\Mage\Core\Controller\Varien\Front.php:158
[3] C
:\xampp\htdocs\magento\app\Mage.php:427
[4] C
:\xampp\htdocs\magento\index.php:40
</pre>

How did you manage to get it work?

 
Magento Community Magento Community
Magento Community
Magento Community
 
alistek
Sr. Member
 
Total Posts:  293
Joined:  2008-04-02
Normal, IL
 

Usually what I have noticed when that happens is that it is because I have done an echo or a var_dump or something that outputs to screen before I intended it.  I will get together the scripts and try to get all of that posted since Mark Kismal said that would be fine.  Look for a post in a little while.

-Adam

 
Magento Community Magento Community
Magento Community
Magento Community
 
nicolas46
Sr. Member
 
Total Posts:  210
Joined:  2008-04-09
Toulouse
 

I will get together the scripts and try to get all of that posted since Mark Kismal said that would be fine.  Look for a post in a little while.

I’m so excited !!! I can’t wait vampire

 
Magento Community Magento Community
Magento Community
Magento Community
 
cibernoid
Sr. Member
 
Avatar
Total Posts:  208
Joined:  2008-02-12
 

I think I have found an error in the book; in the function “ehoXmlArray” the xml tag is not closed (2nd row of the script).
Fixing the error does not solve the blank page and “header already sent” issue I have, though.
The generated Xml can be viewed by looking at the html source with the browser.

I look forward for the script released by alistek, thank you.

 
Magento Community Magento Community
Magento Community
Magento Community
 
porterhouse
Jr. Member
 
Total Posts:  27
Joined:  2008-02-23
 

@VisualFrames—can’t wait til you get it done.  This is the one thing holding us back!  Great to hear it’s almost ready.

 
Magento Community Magento Community
Magento Community
Magento Community
 
the311guy
Sr. Member
 
Avatar
Total Posts:  120
Joined:  2007-10-18
 

I am excited for this order exporter.  Will it export orders to a csv file?  I’m also looking to export all orders “since last export” so that we can easily download orders that need to be shipped.  Will this be implemented?

Looking forward to it.  Thanks for the awesome effort!

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 1 of 7