Skip to content

ExecuteNonQuery error #244

Description

@TerceiraSoft

I am Trying to execute this

SessionAuto.ExecuteNonQuery("UPDATE LinhasPedidosPOS SET Quantidade = @qt WHERE ID = @id", new { Qt = qtd, linha.ID });

ID is a Guid Value

I get this error
Must declare the scalar variable "@qt".

if i use RepoDb to execute the same thing it works fine.

using SqlConnection db = AppHelper.CriarDbConnection;
db.ExecuteNonQuery("UPDATE LinhasPedidosPOS SET Quantidade = @qt WHERE ID = @id", new { Qt = qtd, linha.ID });

What can be the problem with this?

Thanks.

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions