hange connection from default to other onexecution in blank

I want to change the default database connection based on domain name on executing the script in blank application how to do it…
i used sc_edit_conn, but no change in db connection