private void ValidateGrouping()
{
if (!(IsColumnField || IsRowField))
{
throw (new Exception("Field must be a row or column field"));
}
foreach (var field in _table.Fields)
{
if (field.Grouping != null)
{
throw (new Exception("Grouping already exists"));
}
}
}