Fix date check for member type query