Optimize PHP/MYSQL Export Script - PHP/MYSQL Expert Needed

Completed Posted Jan 10, 2012 Paid on delivery
Completed Paid on delivery

I have an existing PHP export script that manipulates some data and then exports the data into a csv file.

The script exports a survey. Each survey typically has around 20 questions (the question vary slightly from survey to survey). Each survey can have around 5000 entrants. The way the questions and answers are stored is by record since the questions are different for each survey.

The problem is some exports take 45 minutes and fail (I need to run them via the command line to complete them).

The problem is the script seems to have been written inefficiently. Instead of the SQL being written to pull in all data in one pass (ie SELECT [url removed, login to view],max(if(field_id=97, field_value,' ')) as '#1', max(if(field_id=98, field_value,' ')) as '#2',,,,,,,,,

group by [url removed, login to view]) and then do some parsing (the actual SQL takes around 8 seconds to run and produce the 5000 entrant records inc column format) in the way I am thinking), it instead does something else in multiple passes and takes 45 minutes to produce csv file. What I am suggesting would need to be written so it is dynamic (every contest has different questions), but I think it would work.

I need a strong MYSQL and php coder to come up with a better script so it runs much faster.

Don't bid unless you have at least 10 positive feedback ratings.

AJAX MySQL PHP

Project ID: #1381050

About the project

7 proposals Remote project Active Jan 11, 2012

Awarded to:

burtzerk

Hi Please see your PMB for details on my bid

$100 USD in 4 days
(24 Reviews)
5.3

7 freelancers are bidding on average $159 for this job

jerrypro

Check PMB.

$200 USD in 3 days
(184 Reviews)
6.1
EfficientDev

I am pretty sure I can fix this for you. I would like to take a look at the database structure. Also, I need to know what is the size of the database.

$200 USD in 2 days
(29 Reviews)
5.6
vijarp

Hello Sir,Strong PHP & MYSQL Developers.........Pls Check PM

$225 USD in 5 days
(22 Reviews)
5.0
giorgioferroli

can do it for you immediatly, have already done much job with php mysql and csv storing. please check pm. thanks

$90 USD in 0 days
(1 Review)
2.1
younglancer

Sir, although I am new to freelancer, I am not new in programming. I have done a similar project in the past, see PM for details.

$100 USD in 2 days
(0 Reviews)
4.0