Login   Register  
PHP Classes
elePHPant
Icontem

csv2mysql database migration tool: convert fields in a csv into SQL

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (3)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2003-06-06 (11 years ago) RSS 2.0 feedStarStarStar 58%Total: 7,654 This week: 1All time: 212 This week: 1,364Down
Version License Categories  
csv2mysql 1.0.0GNU General Public Lice...Databases, Files and Folders
Description Author  

This class creates sql to import into tables in any mysql table - you specify the fieldname in the csv - and the mysql field in your db that this relates to. It supports database queries to get values to go into final sql (so you can link tables) and it supports running custom functions to get values for the final sql too. - and static values for other fields.
It does some validation on the final sql to check that you have all the fields that are required etc.
There is also some (experimental) xls file import support providing you have xlhtml installed on the machine the class is running on. (it will locate it and moan if you haven't) This works if the excel file only has 1 page but if it has multiple pages then im working on it ;)

Picture of Mark Williamson
Name: Mark Williamson <contact>
Classes: 5 packages by
Country: United Kingdom United Kingdom
Age: ???
All time rank: 21812 in United Kingdom United Kingdom
Week rank: 1060 Down47 in United Kingdom United Kingdom Down

  Files folder image Files  
File Role Description
Accessible without login Plain text file csv2mysql instructions Doc. instructions on how to use
Plain text file csv2mysql.inc Class csv2mysql
Accessible without login Plain text file htmltablecreation.inc Aux. creates html tables from structs

 Version Control Unique User Downloads Download Rankings  
 0%Total:7,654All time:212
 This week:1This week:1,364Down
 User Ratings  
 
 All time
Utility:87%StarStarStarStarStar
Consistency:75%StarStarStarStar
Documentation:67%StarStarStarStar
Examples:-
Tests:-
Videos:-
Overall:58%StarStarStar
Rank:1046