Two parameters in documentation but only one specified

The example has:

use Cake\Datasource\ConnectionManager;
use DateTime;

$connection = ConnectionManager::get('default');
$results = $connection
    ->execute(
        'SELECT * FROM articles WHERE created >= :created',
        ['created' => new DateTime('1 day ago')],
        ['created' => 'datetime']
    )
    ->fetchAll('assoc');

This doesn’t seem to make sense, why twice?

Reference: Database Basics - 5.x

If you look at the API definition for the Connection::execute method you will see, that the 3rd parameter is to tell CakePHP what kind of type the given value is

https://api.cakephp.org/5.0/class-Cake.Database.Connection.html#execute()

So its kind of a casting parameter before the query is being executed.

But you shouldn’t need to specify the 3rd parameter if the column created is already a datetime column type in your DBMS.