Implementing Multi-Armed Bandits in the DBMS