Does anybody know if there is a tool availble that will convert flat file data stores to relational database architectures and also look up the foreign keys?

I need this tool to convert cutomers from their old software and database system (mostly flat-file. csv, delimited, or fixed width) to my MySQL driven software system.

I will be doing this often, and need to be able to take advantage of a program that will lookup foreign keys in my db and then enter them into the table I am converting atuomatically. Or at least after I tell it to do it.

Is there even a demand for a product like this, or am I too unique in my needs?
Let me hear your thoughts.