Try this custom validation function on Model.
public function compositUniqueKey($data){
if(isset($this->data[$this->alias]['field1']) && isset($this->data[$this->alias]['field1']) ){
$check = $this->find('first', array(
'conditions' => array(
'field1' => $this->data[$this->alias]['field1'],
'field2' => $this->data[$this->alias]['field2']
)
)
);
if(!empty($check)){
return false;
}
return true;
}else{
return false;
}
}