Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

3

How can I import a csv file to an odoo 8 automatically?

By
fasluca
on 9/18/15, 6:51 AM 1,098 views

I have to import the csv file automatically to odoo.Is there any modules or python script to perform the same?

I am also have the same situation... i didn't get any solution for this , if you got please share with this post.

pks
on 9/19/15, 2:31 AM
2
Logicious
On 9/18/15, 7:03 AM

Through the API, the same records can be created and amended, and external IDs can be set. This, however, requires a lot of the logic that would otherwise be handled by the CSV importer to be coded by hand, in the external application that uses the API to push in data. Pushing data through the API can be automated.

The load() method can be used against any model to load data. This method takes data in the same structure as a CSV file would provide.

The first parameter is an array of field names, like the column headings on a CSV import.

The second parameter is an array of records. Each record is an array of values matching each field.

The API will return a list of errors where they are catered for by OpenERP. Many errors, however, just result in database exceptions on OpenERP and so need to be picked up as an API failure. This is largely because the OpenERP API is not designed as a generic API, but as a part of the GUI, and so the data sent to the API is very much bound to the current state of the application through that GUI. In other words, invalid data will seldom find its way to the API using the OpenERP GUI. 

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 9/18/15, 6:51 AM
Seen: 1098 times
Last updated: 11/4/16, 2:34 AM