Extracting superclass for use by other pojo dao implementations.
Adding test case for null index values.