¡@

Home 

php Programming Glossary: fieldlist

Using PHP to take the first line of a CSV file and create a MySQL Table with the data

http://stackoverflow.com/questions/173498/using-php-to-take-the-first-line-of-a-csv-file-and-create-a-mysql-table-with-the

explode to make sure we are only using the first line. fieldList explode ' ' fileLines 0 separate columns put into array echo.. IF NOT EXISTS `'. tableName.'` '. br n for i 0 i count fieldList i switch gettype fieldList i case 'integer' typeInfo 'int 11.. '. br n for i 0 i count fieldList i switch gettype fieldList i case 'integer' typeInfo 'int 11 ' break case 'float' typeInfo..