Declare @CentralBookingType smallint

Select @CentralBookingType = Convert(Integer,isnull(KeyValue,0)) from HotelSetup WITH (Nolock) where searchkey like '%CentralBookingType%'

if @CentralBookingType=7 
  UPDATE Personel SET UserGroup = 3 WHERE UserGroup = 4


