Pigeon Planner forum

Importing New Records with Excel or CSV formatted Files

Dane · 4 · 2566

Offline Dane

  • Member
    • Posts: 62
    • View Profile
IMPORTING NEW RECORDS WITH EXCEL OR CSV FILES

Is this possible so hundreds of new birds wouldn't have to be entered manually one by one?
« Last Edit: May 09, 2020, 21:03:44 by Dane »
Velocity First Roller Club
(Arizona Chapter)


Offline Dane

  • Member
    • Posts: 62
    • View Profile

Offline Timo

  • Administrator
  • Member
    • Posts: 392
    • View Profile
This is more complex than you'd initially think. Not because importing from Excel is hard, but because of all the edge cases and possible inconsistencies in the data. In Pigeon Planner, the bandnumber consists of 4 parts, so the Excel sheet needs to have 4 columns as well that match those. Same when parents are provided. Also some data like sex is stored as a number (eg. cock=0, hen=1, young=2), which means there needs to be some mapping between the user's data and expected values. Other data that's just stored as a string (colour, loft, ...) is not a problem.

What about handling existing pigeons? In which columns is which data? It's more involved than just reading the file and adding it to the database. I mean, it's not impossible, but probably too much work for how much it'll be used.

There is however a very basic tool to add many pigeons at once, see File=>Add range. It still uses the old 2-field bandformat and is limited to just numbers, but it's a start. Maybe it's just best to extend this a bit more to handle a few different things.


Offline Dane

  • Member
    • Posts: 62
    • View Profile
I understand and for me it is actually not more complex that I would think as I do understand all of the issues normally involved when importing data into different tables from a flat file.  Given I do have some experience in this area, I think I could provide some suggestions.  One would definitely be running the import data through a validation filter so the data being imported could be process without error.  For example, although the sex may be stored as a number, the correct spelling options (cock, hen, young) would be required to pass the validation test.  For the colors, although they are not numbered, they would need to match the colors in the DB exactly in order to pass the validation pre-process.  If a number already existed, that record would be skipped as the process would likely be for the addition of new records only (at least at first).


For sure the pedigree functionality is by far the most important, if things go as I expect, I may have many hundreds of birds to import when I get all the data coming from a friend of mine and it will eventually represent data to be associated with three different lofts (I will take care of that, nothing to do on your part in regards to that).  So my request is a bit self-serving as I could potentially save many many hours of manual entry if an import was possible.
Velocity First Roller Club
(Arizona Chapter)