I have a project of combining 2 Alpha Four tables into one Alpha Anywhere table. My customer uses Alpha Four and created a flat file database. Each year there are only a half dozen fields which will not be carried over to the next year. First they copy the database and rename it for the coming year. Then they purge the data from the fields in which new data will be entered. That way, they have all their customers and data ready to go for the new year. I have the databases for 2013 and 2014 and need to combine them. Actually, only the new customers in 1014 and the previous customer data which is not carried over from year to year, need to be added. Breaking down either of the databases (really tables) was not hard. I broke down the 2013 table into 3 tables by first creating Customerid, Worksiteid and Applicationid fields and then assigning serial values to each. Next I made 3 copies, one for each new table. Then I simply deleted the unnecessary fields in each table. The Application table was a bit trickier because for each record, there was several fields such as Date1, Date2, Date3, Sale1, Sale2, Sale3 etc. I ended up copying the Application table 5 times. Then, in the 1st one, I kept the necessary fields along with the Date1, Sale1, etc. The same for the other 4 except it was Date2, Sale2, etc. Finally, I posted App2 table to App1 table and so on which, after linking the tables, gave me a relational database.
Now I need to add the 2014 table to the 2013 table but only new customers in 2014 along with the 2014 data which, other than the new customers, will only be in the Application table. Breaking it down as I did for 2013 is not a problem. The trick is to match the 2014 data to the customers in 2013 Application table. Because there are more customers in the 2014 table, assigning new id numbers will not match things up. Not sure I explained this thorough enough to make sense but any ideas and/or suggestions will be greatly appreciated.
EDIT: Well, I appended the 2013 table to the 2014 table and then assigned he customerid numbers to each record. Then I did a mark duplicate records operation matching by last name and first name. Now, all I have to do is assign the worksiteid and the applicationid numbers and then break it down into the 3 tables as stated above. Once that is done, I will remove the duplicate customers and that pretty much should do it.
Now I need to add the 2014 table to the 2013 table but only new customers in 2014 along with the 2014 data which, other than the new customers, will only be in the Application table. Breaking it down as I did for 2013 is not a problem. The trick is to match the 2014 data to the customers in 2013 Application table. Because there are more customers in the 2014 table, assigning new id numbers will not match things up. Not sure I explained this thorough enough to make sense but any ideas and/or suggestions will be greatly appreciated.
EDIT: Well, I appended the 2013 table to the 2014 table and then assigned he customerid numbers to each record. Then I did a mark duplicate records operation matching by last name and first name. Now, all I have to do is assign the worksiteid and the applicationid numbers and then break it down into the 3 tables as stated above. Once that is done, I will remove the duplicate customers and that pretty much should do it.
Comment