2

Can feeds module still know how to map the fields correctly even if there are no headers in a .csv file. I am trying to migrate sample data from database which i exported to a .csv file through phpmyadmin. i am testing the feeds module if it can handle large file migrate.

if the answer is no, can i manually input the headers in the excel files? or it has to be exported again with headers?

1 Answer 1

4

The Feeds module support CSV files without column headers. On admin/structure/feeds/foo_importer/settings/FeedsCSVParser, you just need to select "No Headers". Then on admin/structure/feeds/foo_importer/mapping, you use the column numbers for the source.

Be careful when entering the Name of source field. Your first column is named '0', the second '1' and so on.

6
  • Thanks @Triskelion for the reminder about the column numbers.
    – mpdonadio
    Commented Mar 30, 2013 at 21:01
  • So the source field i am suppose to enter is the numbers? not the actual name of the source field? im talking about the mapping page in feeds. Commented Mar 30, 2013 at 21:01
  • 1
    @Belmark Yes, use the column number. Column A in the XLS is 0, B is 1, C is 2, etc.
    – mpdonadio
    Commented Mar 30, 2013 at 21:02
  • 1
    I get the error: You must select a mapping source. when I enter 0 as a source column.
    – Batandwa
    Commented Jul 1, 2014 at 20:20
  • @Batandwa I think the problem is that you need to select "No Headers", but I would need to remember which site I have, as all of my recent sites have used headers.
    – mpdonadio
    Commented Jul 1, 2014 at 20:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.