Hello Everybody, I am facing a problem that i have an e-commerce website built in django in which i want to have a massive product upload facility. There has to be a panel where merchant can upload a csv file(format should be table structure, i.e. first row will contain headers and rest will contain data) after that we will populate two form to map csv headers with model fields and when user maps them (mapper could be some drop-down thing), data should go in database. If you know any good library for this. In the mean time i am looking at "django-csv-importer". -- Thanks and Regards RAKESH KUMAR http://raakeshkumar.wordpress.com
On Tue, Oct 23, 2012 at 5:47 PM, Raakesh kumar <kumar3180@gmail.com> wrote:
Hello Everybody, I am facing a problem that i have an e-commerce website built in django in which i want to have a massive product upload facility. There has to be a panel where merchant can upload a csv file(format should be table structure, i.e. first row will contain headers and rest will contain data) after that we will populate two form to map csv headers with model fields and when user maps them (mapper could be some drop-down thing), data should go in database. If you know any good library for this. In the mean time i am looking at "django-csv-importer".
Using the csv module in the python standard library you can read the csv file and loop over the data and populate the model user selects. -- blog : ragsagar.wordpress.com mail id : python -c "print '@'.join(['ragsagar','.'.join([x for x in ['gmail','com']])])"
Using the csv module in the python standard library you can read the csv file and loop over the data and populate the model user selects.
dsv module is also available separately for reading delimiter separated
variables. Here is its description for reference:- Python-DSV is an alternative to Python's standard csv module, with somewhat different usage and optional support for wxWidgets-mediated user interaction in the course of format autodetection. Like the standard module, it supports a wide range of delimiters and handles both import and export. I have used it for some huge files without any problems. Regards HB
participants (3)
-
hildebrand victor -
Raakesh kumar -
ragsagar