I am looking for a generic php script that will let me select a csv file (see sample below) and insert the data in the file in to a mysql database. Details of the the upload should be displayed on the screen. In case of errors, the exact error and line number should also be mentioned. The following features are required.
1) The database name, server ip, username and password would be configured in the script.
2) The table name would be the first row of the csv file.
3) The column names would be the second row of the csv file.
4) The delimiter used in the CSV would be comma (,) but it should be configurable at the top of the script in case I need to change it. All data elements would be enclosed in double quotes ("). Commas in between two double quotes should be ignored.
5) MySQLi should be used.
6) mysqli_real_escape_string() Function should be used to escape any special character.
7) After completing the execution of the script, the number of records inserted should be displayed.
8) In case of error, the entire file should be rolled back using mysql transactions. The line number and error details of the first encountered error should be displayed.
9) Basic validation of the csv file should be done. The following errors should be captured.
-a The database and table name should be a valid one.
-b Column names in the file should be found in the table.
-c Right number of data elements based on the first row
-d Proper enclosure of data in double quotes.
-e NULL values being inserted into NON-NULL columns.
-f proper handling of string and numeric values.
10) The script should be able to handle up to 10,000 rows.
SAMPLE CSV FILE
===============================
"Employees"
"Employee_Name","job_title","salary"
"Mike","CEO","500000.00"
"John","Manager","100000.00"
"Mark","Supervisor","25000.00"
===============================
Hello.
I'm professional web developer since 2006. My specifications: eCommerce and custom scripts.
I have experience in such areas: PHP, MySQL, HTML5, CSS3, JavaScript, Bootstrap, jQuery, XML, csv.
I can develop this script.
Regards
HELLO THERE,
Over 200+ Positive Reviews.
Over 90% Completion Rate.
5 Star Rating.
10+ Years of experience in PHP/MYSQL
I AM INTERESTED IN WORKING ON THIS PROJECT.
PLEASE CHECK MY REVIEWS AND THEN DECIDE ON ME.
LOOKING FOR A LONG TERM RELATIONSHIP.
--------------
THANKS,
AJIT
Hello Sir,
hope you are fine,
I am interested in your work "Generic PHP script".
I will create this application in Custom PHP
I have 5 year experience in Web Development Service I am able to this job quickly.
You can view my profile for details to skills and customer feedback
https://www.freelancer.com/u/kazimking
Hi!
I can help you with this project.
Had a similar experience about uploading CSV and importing to MySQL.
Do you need any special UI?
Ready to discuss in chat
Hi, I'm Ing of systems With over 10 years of experience developing large-scale applications and providing web technology solutions for freelancers , small, medium and large businesses.
Habilidades y experiencia relevante
1) HTML5 + CSS3
2) PHP POO laravel, Zend
3) Javascript Boostrap, Jquery, Angular
4) Database Mysql, Oracle, Postgresql
5) GIT, SVN
Thanks good day.
Sir that's a pretty straightforward project, I have read it. I'm new to this platform that's why my bid is low, I just need a good review, I will do the best work for you.
I completely understand your requirements.
I have experience working in CSV parsing and insertion in database. I will also use proper validations before inserting data in database. I will also use transactions, so that data can be rolled back.
I have 4+ experience in PHP and MySQL and I ensure you that you will be getting only quality work.
Hello
I understood that you are looking for a configurable PHP script where you can put any excel data into any table of your choice. You want to have access to choose DB, table, columns, CSV delimeter and show relevant error info on failure + rollback MYSQL transaction (or) show number of inserted rows.
I can build the script in native PHP with MYSQL support with configuration file where you can make the changes.
Respected Sir,
Thank you for taking the time to read our initial posting.
I have read initial project description and i am ready to start this project.I have done similar project by using pdf and excel also.
For further details, please message in the pmb.
Look forward to hearing from you.
Thanks,
Nomakram
I am a web developer in PHP and MYSQL.I have inhand 4 years of experience in this field.I have also worked in Ajax ,Javascript,Codeigniter,wordpress and Joomla.I am sure I can complete the task within the timestamp as per the requirements.
Hi
I'm PHP guru
I already have a generic PHP for CRUD and upload. You just define table structure in XML and run.
escaping , datatypes a dynamically managed
I can demo you the script
Hire me to update this script and release yours