Skip to content

Inserting results from previous query not possible #247

Description

@prkwcz

I have a script that collects data from different sources and imports it into a MariaDB database.
Practically it looks like this:

// Getting all the necessary import sets
$db1Result = $db1->fetchAll("SELECT A, B, C FROM XYZ");

//Importing to the new database
$db2->query("INSERT INTO ZYX", $db1Result);

But then I always get the following error message:
Automaticaly detected multi-insert, but values aren't array. If you need try to change mode like "?[and|or|set|values|order]". Mode "values" was used.

In fact, this seems to be a bug in version 3. Here it seems that no ResultSet is accepted as input for the insert anymore.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions