Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
06-08-2011, 09:46 AM #1
- Join Date
- Aug 2010
- Thanked 0 Times in 0 Posts
Program to import MySql data for me?
I run a fairly large & popular community based website but currently cannot afford to pay someone to update my import scripts (php/mysql), which import data from affiliates to populate a table in our database. Problem is the partners/affiliates are sometimes changing their schema, which they have done recently.
I'm therefore currently inserting the data manually, but its taking a good 5 minutes a row, and there are thousands of rows ahead of me. I'm therefore wondering if there is available software that allows you to import data by simply matching fields in a csv file to the database fields?
Some rows would need to be new, some rows would need just a few fields updating. Is there software that can do this? It would need to fuzzy match a 'Name' field for each row etc.
There are some linked tables but I could bypass those for now.
I realise i could be clutching at straws here but any info would be appreciated. Many thanks!
06-08-2011, 04:17 PM #2
- Join Date
- Dec 2005
- Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
- Thanked 637 Times in 625 Posts
If you can standardize the import file, it will be a simple matter. In other words, separate the INSERTs from the UPDATEs. Make sure every record in the import file has clean and consistent data.
06-08-2011, 07:06 PM #3
The "fuzzy" match on name is the tough part. How fuzzy? What is the tolerance level? If it's so fuzzy that only a human can make the decision, then you are probably hosed. But if you can figure out an algorithm for doing the fuzzy match, then it seems simple enough.
All you would need to do is provide a "mapping" of the columns in the external data to the columns in your db table. And then you could write a simple PHP program to read from the external data, test for the fuzzy match, and then insert or update the db data as appropriate.
But it really all depends on that fuzzy matching.