Use SQL database as a flexible key-value storage