Posted on 2012-09-02
I am importing a csv file into my Database. It is a comma delimitered file.
I have 2 tables
tPhonebook - ID, sBook
tContacts - ID, sName, sPhone, iPhonebookID
iPhonebookID is linked to ID of tPhonebook
The csv file consists of
Column 1 - Name
Column 2 - Number
Column 3, 4, 5 etc is the name of a Phonebook.
I need the import to add a phone book for every column named after column 2, it could be one or multiple columns, it is different for every row.
I then need it to add that contact to each phone book and move to the next row.
If the phone book exists already I just need to ID for iPhonebookID.