SQL::Engine::Operation

SQL Operation

SQL Statement Operation

method: parameters

use SQL::Engine::Operation;

my $operation = SQL::Engine::Operation->new(
  statement => 'SELECT * FROM "tasks" WHERE "reporter" = ? AND "assigned" = ?',
  bindings => {
    0 => 'user_id',
    1 => 'user_id'
  }
);

# my @bindings = $operation->parameters({
#   user_id => 123
# });

Types::Standard

bindings: ro, req, HashRef statement: ro, req, Str

This package provides SQL Statement Operation.

The parameters method returns positional bind values for use with statement handlers.

parameters(Maybe[HashRef] $values) : ArrayRef

=example-1 parameters

# given: synopsis

my $bindings = $operation->parameters({
  user_id => 123
});

# [123, 123]

10 POD Errors

The following errors were encountered while parsing the POD:

Around line 10:

Unknown directive: =name

Around line 16:

Unknown directive: =tagline

Around line 22:

Unknown directive: =abstract

Around line 28:

Unknown directive: =includes

Around line 34:

Unknown directive: =synopsis

Around line 52:

Unknown directive: =libraries

Around line 58:

Unknown directive: =attributes

Around line 65:

Unknown directive: =description

Around line 71:

Unknown directive: =method

Around line 76:

Unknown directive: =signature