Here is an example of how to build a ValRep array with composite keys:
$this->sql_select = 'part1, part2, description';
$this->sql_orderby = 'part1, part2';
$this->sql_ordery_seq = 'asc';
$data = $this->getData(null);
// convert each row into 'id=desc' in the output array
foreach ($data as $row => $rowdata) {
$key = $rowdata['part1].'/'.$rowdata['part2'];
$array[$key] = $rowdata['description'];
} // foreach
return $array;
Note here that each key string is in the format 'part1/part2' with '/' as the separator. When the selected key is sent in via the $_POST array you have to split this single string field back into its component parts.