Update [tablename] set xxx=Replace(xxx,'XXX','YYY') where left(xxx,3)='XXX'