Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import of csv fails Invalid product lines #48

Closed
torian257x opened this issue Jun 23, 2016 · 2 comments
Closed

Import of csv fails Invalid product lines #48

torian257x opened this issue Jun 23, 2016 · 2 comments

Comments

@torian257x
Copy link

torian257x commented Jun 23, 2016

I was following this guide:

https://aimeos.org/docs/Developers/Controller/Import_products_from_CSV

so i downloaded their csv

my setup:
/home/myuser/IdeaProjects/myapp/ff-laravel/database/csvimport/products-import-example.csv

shop.php


  'controller' => array(
    'jobs' => array(
      'product' => array(
        'import' => array(
          'csv' => array(
            'location' => '/home/myuser/IdeaProjects/myapp/ff-laravel/database/csvimport/'

          )
        )
      )
    )
  ),

command:

php artisan aimeos:jobs "product/import/csv" -vvv

error:


Executing the Aimeos jobs for "default"


  [Aimeos\Controller\Jobs\Exception]                                                                    
  Invalid product lines in "/home/myuser/IdeaProjects/myapp/ff-laravel/database/csvimport/": 1/3  


Exception trace:
 () at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/aimeos/aimeos-core/controller/jobs/src/Controller/Jobs/Product/Import/Csv/Standard.php:369
 Aimeos\Controller\Jobs\Product\Import\Csv\Standard->run() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/aimeos/aimeos-laravel/src/Aimeos/Shop/Command/JobsCommand.php:60
 Aimeos\Shop\Command\JobsCommand->fire() at n/a:n/a
 call_user_func_array() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/laravel/framework/src/Illuminate/Container/Container.php:507
 Illuminate\Container\Container->call() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/laravel/framework/src/Illuminate/Console/Command.php:150
 Illuminate\Console\Command->execute() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/symfony/console/Command/Command.php:256
 Symfony\Component\Console\Command\Command->run() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/laravel/framework/src/Illuminate/Console/Command.php:136
 Illuminate\Console\Command->run() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/symfony/console/Application.php:841
 Symfony\Component\Console\Application->doRunCommand() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/symfony/console/Application.php:189
 Symfony\Component\Console\Application->doRun() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/symfony/console/Application.php:120
 Symfony\Component\Console\Application->run() at /home/myuser/IdeaProjects/myapp/ff-laravel/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php:107
 Illuminate\Foundation\Console\Kernel->handle() at /home/myuser/IdeaProjects/myapp/ff-laravel/artisan:36


can it be that the example file is not working for us? or is it a different problem, say i set up things wrong or misunderstood the doc?

@torian257x
Copy link
Author

so the deal was: you have to remove the top line with all the subjects of the columns in the csv file.

@aimeos
Copy link
Owner

aimeos commented Jun 23, 2016

Thanks for the hint. We've updated the documentation and added some hints about the skip-lines configuration and the logging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants