Time Based Key Value Store Leetcode Sql 50