add_action( 'admin_init', 'set_page_templates' );

function set_page_templates(){
$current_template = get_post_meta( $page->ID, '_wp_page_template', true );
echo $current_template.'amit';
    foreach( get_posts('post_type=post&posts_per_page=-1') as $page ) {
        $current_template = get_post_meta( $page->ID, '_wp_page_template', true );
        $new_template = 'yourpage-template.php';

        if( $current_template != $new_template )
            update_post_meta( $page->ID, '_wp_page_template', $new_template );
    }

}