/**
  * Takes the input parameter and extract the table name (alias) and column name
  * @param array $query_param  like Registration.Transaction.TXN_ID, Event.Datetime.start_time, or REG_ID
  * @throws EE_Error
  * @return string table alias and column name for SQL, eg "Transaction.TXN_ID"
  */
 private function _deduce_column_name_from_query_param($query_param)
 {
     $field = $this->_deduce_field_from_query_param($query_param);
     if ($field) {
         $table_alias_prefix = EE_Model_Parser::extract_table_alias_model_relation_chain_from_query_param($field->get_model_name(), $query_param);
         return $table_alias_prefix . $field->get_qualified_column();
     } elseif (array_key_exists($query_param, $this->_custom_selections)) {
         //maybe it's custom selection item?
         //if so, just use it as the "column name"
         return $query_param;
     } else {
         throw new EE_Error(sprintf(__("%s is not a valid field on this model, nor a custom selection (%s)", "event_espresso"), $query_param, implode(",", $this->_custom_selections)));
     }
 }