Problem
Move WordPress blog from one domain to another domain. After moving all the wordpress files and database, all the blogs still pointed to the old domain.

Solution
Need to change two entries in the wordpress_options table in wordpress database: option_id 2 – siteurl and option_id 39 – home. Change both of them from old_domain to new_domain

Example, change wordpress from http://www.old_domain.com to http://www.new_domain.com.
1. Change siteurl from http://www.old_domain.com/ to http://www.new_domain.com/
2. Change home from http://www.old_domain.com/ to http://www.new_domain.com/

From mysql’s command line, switch to your wordpress database with

use wordpress_db

then you can use SQL statement:
update wp_options set option_value =’http://www.new_domain.com/’ where option_id = ‘2’;

update wp_options set option_value =’http://www.new_domain.com/’ where option_id = ’39’;

That’s it. Your wordpress blogs will point to the new_domain.

Reference
WordPress Codex