The Little Guy Posted September 18, 2010 Share Posted September 18, 2010 I downloaded database that is binary, it is only about 30MB, there is the exact same database that I downloaded (from the same website just different format) that is CVS, and I converted it to a mysql database and it is over a 1GB in size. Why did searching for the same thing in the mysql database take 30+ seconds to do, and less than 1 second in the binary database? website: http://www.maxmind.com/app/geolitecity Both binary and CVS downloads are on this page. Quote Link to comment Share on other sites More sharing options...
PugJr Posted September 21, 2010 Share Posted September 21, 2010 C++ VS. PHP Why is C++ so much faster than PHP? When a language or program appeals to novices, it loses speed. Why do you think PHP/MySQL are very popular? ( Also why else would I be using PHP/MySQL? ) Quote Link to comment Share on other sites More sharing options...
xylex Posted September 21, 2010 Share Posted September 21, 2010 Did you do anything to optimize your query in MySQL? Create relevant indexes, etc? Or are you comparing a highly tuned compiled data source to a fresh drop of a CSV in MySQL? Tuned properly, MySQL should be able to query as fast as the C++ library, though MySQL will always be a much bigger footprint as it gives you a whole lot of other things the C++ library doesn't. Quote Link to comment Share on other sites More sharing options...
Daniel0 Posted September 21, 2010 Share Posted September 21, 2010 C++ VS. PHP Why is C++ so much faster than PHP? When a language or program appeals to novices, it loses speed. Why do you think PHP/MySQL are very popular? ( Also why else would I be using PHP/MySQL? ) MySQL isn't written in neither PHP nor C++, so your point is irrelevant. The querying speed on the MySQL database vs. the querying speed on the binary version of the database is the subject here. The API for querying the binary version is available in a multitude of languages, including PHP. Quote Link to comment Share on other sites More sharing options...
PugJr Posted September 22, 2010 Share Posted September 22, 2010 I see my anology wasn't clearly said. The anology was 'does not appeal to novices':'appeals to novices'::'does not appeal to novices':'appeals to novices' My point is MySQL, like PHP, adds alot of flexibility at the price of speed. Not that MySQL is written in one language or another. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.