the error message "Prepared statement contains too many Placeholders" is clear, the values you provide in the query is less than the placeholders or does not match....
Aug 28, 2019
8
Level 9
Too many placeholders
Good afternoon.
I have a problem entering a large amount of data ... +10 million rows.
The process itself is simple.
- Read the file.
- Validate each line.
- Insert valid rows in the database.
But when I try to insert this large amount. I get the following error.
Illuminate \ Database \ QueryException: SQLSTATE [HY000]: General error: 1390 Prepared statement contains too many Placeholders
at api / vendor / laravel / framework / src / Illuminate / Database / Connection.php: 664
660 | // If an exception occurs when attempting to run a query, we'll format the error
661 | // message to include bindings with SQL, which will make this exception a
662 | // lot more helpful to the developer instead of just the database's errors.
663 | catch (Exception $ e) {
> 664 | throw new QueryException (
665 | $ query, $ this-> prepareBindings ($ bindings), $ and
666 | );
667 | }
668 |
Please or to participate in this conversation.