.. _must-be-a-list-array:
must be a list array
--------------------
.. meta::
:description:
must be a list array: This error is reported when the provided list of parameters, in ``mysqli_stmt_execute()`` or ``mysqli::stmt_execute()`` is not a list: the index must start at 0, and be auto-generated.
:og:image: https://php-errors.readthedocs.io/en/latest/_static/logo.png
:og:type: article
:og:title: must be a list array
:og:description: This error is reported when the provided list of parameters, in ``mysqli_stmt_execute()`` or ``mysqli::stmt_execute()`` is not a list: the index must start at 0, and be auto-generated
:og:url: https://php-errors.readthedocs.io/en/latest/messages/must-be-a-list-array.html
:og:locale: en
:twitter:card: summary_large_image
:twitter:site: @exakat
:twitter:title: must be a list array
:twitter:description: must be a list array: This error is reported when the provided list of parameters, in ``mysqli_stmt_execute()`` or ``mysqli::stmt_execute()`` is not a list: the index must start at 0, and be auto-generated
:twitter:creator: @exakat
:twitter:image:src: https://php-errors.readthedocs.io/en/latest/_static/logo.png
.. raw:: html
Description
___________
This error is reported when the provided list of parameters, in ``mysqli_stmt_execute()`` or ``mysqli::stmt_execute()`` is not a list: the index must start at 0, and be auto-generated.
Example
_______
.. code-block:: php
$val3]);
?>
Solutions
_________
+ Check that no index is explicitly named in the array of parameters.
+ Apply array_values() to make the array a list.
Changed Behavior
________________
This error may appear following an evolution in behavior, in previous versions. See ` `_.