# BatchOperation

Required Frends version: 5.7+

Required .NET version: 8.0

Compatible Agents: Unknown

Source code: <https://github.com/FrendsPlatform/Frends.Snowflake/tree/main/Frends.Snowflake.BatchOperation>

{% tabs %}
{% tab title="Parameter: Input" %}

| Name                | Description                                                                                                                                                         |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Query : `String`    | <p>Query to perform.</p><p><br>Default: <code>-</code><br>Example: <code>INSERT INTO TableName (NAME, AGE) VALUES (:Name, :Age)</code></p>                          |
| JsonData : `String` | <p>Json data in a specific format</p><p><br>Default: <code>-</code><br>Example: <code>\[ { "Name": "Matti", "Age": 12 }, { "Name": "Joni", "Age": 34 } ]</code></p> |
| {% endtab %}        |                                                                                                                                                                     |

{% tab title="Parameter: Connection" %}

| Name                              | Description                                                                                                                                                                                                                  |
| --------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| ConnectionString : `String`       | <p>Connection string to Snowflake.</p><p><br>Default: <code>-</code><br>Example: <code>account=myaccount;host=myaccount.snowflakecomputing.com;user=myuser;db=mydb;schema=public</code></p>                                  |
| PrivateKeyFilePath : `String`     | <p>Full file path to the private key (.p8) used for Snowflake key pair authentication.</p><p><br>Default: <code>-</code><br>Example: <code>C:\keys\rsa\_key.p8</code></p>                                                    |
| 🗝PrivateKeyPassphrase : `String` | <p>Optional passphrase for the private key file, if the key was generated with encryption.</p><p>Leave empty if the key file is unencrypted.</p><p><br>Default: <code>-</code><br>Example: <code>MySuperSecret123</code></p> |
| {% endtab %}                      |                                                                                                                                                                                                                              |

{% tab title="Parameter: Options" %}

| Name                             | Description                                                                                                                    |
| -------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
| ThrowErrorOnFailure : `Boolean`  | <p>Whether to throw an error on failure.</p><p><br>Default: <code>True</code><br>Example: <code>true</code></p>                |
| ErrorMessageOnFailure : `String` | <p>Overrides the error message on failure.</p><p><br>Default: <code>-</code><br>Example: <code>Custom error message</code></p> |
| {% endtab %}                     |                                                                                                                                |

{% tab title="Result: Result" %}

| Name                   | Description                                                                                                                    |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
| Success : `Boolean`    | <p>Indicates if the task completed successfully.<br>Example: <code>true</code></p>                                             |
| AffectedRows : `Int32` | <p>Number of affected rows.<br>Example: <code>2</code></p>                                                                     |
| Error : `Error`        | <p>Error that occurred during task execution.<br>Example: <code>object { string Message, Exception AdditionalInfo }</code></p> |
| {% endtab %}           |                                                                                                                                |

{% tab title="Changelog" %}

## Changelog

### \[1.1.0] - 2026-02-23

#### Fixed

* Ensure FrendsTaskMetadata.json is included in NuGet package

### \[1.0.0] - 2026-02-12

#### Added

* Initial implementation
  {% endtab %}
  {% endtabs %}
