which common prime minister did edward stanley and william weir serve ?
SELECT DISTINCT var_uri where brack_open dbr_Edward_Stanley,_17th_Earl_of_Derby dbo_primeMinister var_uri sep_dot dbr_William_Weir,_1st_Viscount_Weir dbo_primeMinister var_uri brack_close