Skip to content

execute() does not fail if an incorrect number of parameters is specified #18

@philip-stoev

Description

@philip-stoev

Statements such as:

    cursor.execute("SELECT ? FROM DUAL");
    cursor.execute("SELECT ?, ? FROM DUAL", []);

must fail with an exception such as "wrong number of parameters specified, expected X got Y". Otherwise, simple typos may lead to data loss or wrong results.

Others fail with an exception "TypeError: init() takes exactly 2 arguments (1 given)" which is not very informative.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions