And here is a complete hack if you want custom named values for the
table-names (I use derived)
function resultSet(&$results) {
$this->results =& $results;
$this->map = array();
$num_fields = mysql_num_fields($results);
$index = 0;
$j = 0;
while ($j < $num_fields) {
$column = mysql_fetch_field($results,$j);
if (!empty($column->table)) {
if (!(strpos($column->table,'#sql_')===false))
{
$this->map[$index++] = array('derived',
$column->name);
}
else
{
$this->map[$index++] =
array($column->table, $column->name);
}
} else {
$this->map[$index++] = array(0, $column->name);
}
$j++;
}
}
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Cake PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---