I am converting all mysql coding to PDO and am receiving this error -

**Warning: PDO::exec() expects parameter 1 to be string, array given in**

Below is the code:

```
$ent_date = $array[1];
$ent_time = $array[2];
$card_no = $array[3];

try {
    $att = new PDO('mysql:host=localhost;dbname=att', 'root', '');
    $att->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
    $att1 = 'insert into att_detail (att_date,att_time,att_card_no) values (:date_ent,:time_ent,:cardno)';
    $att -> exec(array(
                        ':date_ent'=>$ent_date,
                        ':time_ent'=>$ent_time,
                        ':cardno'=>$card_no));
     echo "new record created";
    }
catch (PDOException $e){
                        echo $att . "<BR>" . $e->getMessage();
                     }

$att = null;

```

Appreciate any help in understanding the quickest way to resolve.