GetFieldIndex

Compute the field indexand output given a field type