Jump to content


Photo

Excel to MySQL Database


  • Please log in to reply
No replies to this topic

#1 Hardbyte

Hardbyte
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts
  • LocationMidlands, UK

Posted 19 May 2006 - 03:33 PM

Hi,

I couldnt find a script/program anywhere to convert my .xls of 100ish users into a MySQL format to upload to my SQL database.

I wrote a php script that will take take your .xls (Im not that good with MS-Office - its just a list of usernames, names and passwords) and put it into the following format:-

INSERT INTO '[tablename]' VALUES ('your', 'xls', 'document', 'details');

I think this is the correct format if you are able to use the SQL feature of phpMyAdmin. This will loop through all your entries of your .xls file. Just make sure your .xls document is in the correct order of your database.

Would this be any good for anyone else? Or please let me know of what other people use so I can improve on my part. Im just a beginner so any comments would be appreciated.

Regards

Hardbyte.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users