What is the significance of the index starting at 0 in the array when using it in the SQL query?

When using an array in an SQL query, it's important to remember that the index starts at 0. This means that when referencing elements in the array, you need to subtract 1 from the index to match the correct position in the SQL query.

// Example of how to correctly reference array elements in an SQL query
$array = ['value1', 'value2', 'value3'];

// Correctly referencing the array elements in the SQL query
$query = "SELECT * FROM table WHERE column = '" . $array[0] . "' OR column = '" . $array[1] . "' OR column = '" . $array[2] . "'";