Tracker.Batch.add_statement

### Method

# Tracker Batchadd_statement

since: 3.5

#### Declaration [src]

    void
    tracker_batch_add_statement (
      TrackerBatch* batch,
      TrackerSparqlStatement* stmt,
      ...
    )

#### Description [src]

Adds a `TrackerSparqlStatement` containing an SPARQL update. The statement will be executed once in the batch, with the parameters bound as specified in the variable arguments.

The variable arguments are a NULL terminated set of variable name, type `GType`, and value. The value C type must correspond to the given `GType`. For example, for a statement that has a single `~name` parameter, it could be given a value for execution with the following code:

    tracker_batch_add_statement (batch, stmt,
                                 "name", G_TYPE_STRING, "John Smith",
                                 NULL);

A `TrackerSparqlStatement` may be used on multiple `tracker_batch_add_statement()` calls with the same or different values, on the same or different `TrackerBatch` objects.

This function should only be called on `TrackerSparqlStatement` objects obtained through `tracker_sparql_connection_update_statement()` or update statements loaded through `tracker_sparql_connection_load_statement_from_gresource()`.

Available since: 3.5

This method is not directly available to language bindings.

The implementation of this method is provided by `tracker_batch_add_statementv()` in language bindings

#### Parameters

`stmt`

  Type: `TrackerSparqlStatement`

  A `TrackerSparqlStatement` containing a SPARQL update.

  The data is owned by the caller of the method.

`...`

  Type: ``

  NULL-terminated list of parameters bound to `stmt`, in triplets of name, type and value.