Prepend table name to avoid ambiguity

This commit is contained in:
Nathan Gray 2012-05-14 18:03:42 +00:00
parent 7810068ed0
commit fe7814b64c

View File

@ -931,7 +931,12 @@ class so_sql
}
if ($only_keys === true)
{
$colums = implode(',',array_keys($this->db_key_cols));
$colums = array_keys($this->db_key_cols);
foreach($colums as &$column)
{
$column = $this->table_name . '.' . $column;
}
$colums = implode(',',$colums);
if (!empty($colums)) $colums = ' DISTINCT '.$colums;
}
elseif (is_array($only_keys))