Skip to content

Calling multiple stored procedures #7

@Krojack

Description

@Krojack

When calling multiple stored procedures, you can run into the following error: "Commands out of sync; you can't run this command now". I added the following to my class.db.php and then call it after calling the procedure query.

public function next_result()
{
$this->link->next_result();
}

So now I run this without the error.

$db->get_row( "CALL calcMedian('table_name','col_name')" );
$db->next_result();
$db->get_row( "CALL calcMedian('table_name','col_name')" );
$db->next_result();

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions