|
![](images/space.gif)
|
|
$pc = '123-4567-00';
$sth->prepare("SELECT * FROM PRODUCTS WHERE PROD_CODE = '$pc'")
$sth->execute();
or
$sth->prepare("SELECT * FROM PRODUCTS WHERE PROD_CODE = ?")
$sth->execute($pc); |
![](images/space.gif) |
![](images/bullet.gif) |
Multiple executions |
![](images/space.gif) |
![](images/bullet.gif) |
Automatic quoting |
![](images/space.gif) |
![](images/bullet.gif) |
Safer than string interpolation |
![](images/space.gif) |
|
|
|