Phases of data mining