---
title: "Add ETL Operation"
url: "https://docs.ravendb.net/6.2/client-api/operations/maintenance/etl/add-etl"
version: "6.2"
language: "nodejs"
---

# Add ETL Operation

> Client language: Node.js. Also available for [C#](https://docs.ravendb.net/6.2/client-api/operations/maintenance/etl/add-etl.md), [Java](https://docs.ravendb.net/6.2/client-api/operations/maintenance/etl/add-etl.java.md).
>
> RavenDB publishes an official agent skill for coding assistants at https://docs.ravendb.net/skills/ravendb/SKILL.md (also installable with `npx skills add ravendb/skills`). The skill describes itself as: "Read this before writing any RavenDB query, client call or /databases/ request. Covers server setup, document modelling, the Node.js, .NET and Python clients, RQL, indexes, vector search and AI agents. Code written from recall tends to run and return the wrong rows, because RQL resembles SQL and the clients take field names as plain strings."

> **Note**
>
> - Use the `AddEtlOperation` method to add a new ongoing ETL task to your database.
>
> - To learn about ETL (Extract, Transfer, Load) ongoing tasks, see article [ETL Basics](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/basics.md).  
>   To learn how to manage ETL tasks from the Studio, see [Ongoing tasks - overview](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/general-info.md).
>
> - In this page:
>   - [Example - add Raven ETL](#example---add-raven-etl)
>   - [Example - add SQL ETL](#example---add-sql-etl)
>   - [Example - add OLAP ETL](#example---add-olap-etl)
>   - [Syntax](#syntax)

## Example - add Raven ETL

```javascript
const etlConfigurationRvn = Object.assign(new RavenEtlConfiguration(), {
  connectionStringName: "raven-connection-string-name",
  disabled: false,
  name: "etlRvn"
});

const transformationRvn = {
  applyToAllDocuments: true,
  name: "Script #1"
};

etlConfigurationRvn.transforms = [transformationRvn];

const operationRvn = new AddEtlOperation(etlConfigurationRvn);
const etlResultRvn = await store.maintenance.send(operationRvn);
```

## Example - add SQL ETL

```javascript
const transformation = {
  applyToAllDocuments: true,
  name: "Script #1"
};

const table1 = {
  documentIdColumn: "Id",
  insertOnlyMode: false,
  tableName: "Users"
};

const etlConfigurationSql = Object.assign(new SqlEtlConfiguration(), {
  connectionStringName: "sql-connection-string-name",
  disabled: false,
  name: "etlSql",
  transforms: [transformation],
  sqlTables: [table1]
});

const operationSql = new AddEtlOperation(etlConfigurationSql);
const etlResult = await store.maintenance.send(operationSql);
```

## Example - add OLAP ETL

```javascript
const transformationOlap = {
  applyToAllDocuments: true,
  name: "Script #1"
};

const etlConfigurationOlap = Object.assign(new OlapEtlConfiguration(), {
  connectionStringName: "olap-connection-string-name",
  disabled: false,
  name: "etlOlap",
  transforms: [transformationOlap],
});

const operationOlap = new AddEtlOperation(etlConfigurationOlap);
const etlResultOlap = await store.maintenance.send(operationOlap);
```

## Syntax

```javascript
const operation = new AddEtlOperation(etlConfiguration);
```

| Parameter | Type | Description |
| - | - | - |
| **configuration** | `EtlConfiguration` object | The ETL task configuration to add |

```javascript
class EtlConfiguration {
  taskId?;     // number
  name;        // string
  mentorNode?: // string
  connectionStringName; // string
  transforms;  // Transformation[]
  disabled?;   // boolean
  allowEtlOnNonEncryptedChannel?; // boolean 
}
```

## See also

- [ETL basics](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/basics.md)
- [RavenDB ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/raven.md)
- [SQL ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/sql.md)
- [OLAP ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/olap.md)
- [Elasticsearch ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/elasticsearch.md)
- [Kafka ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/queue-etl/kafka.md)
- [RabbitMQ ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/queue-etl/rabbit-mq.md)
- [Azure Queue Storage ETL](https://docs.ravendb.net/6.2/server/ongoing-tasks/etl/queue-etl/azure-queue.md)
- [Ongoing tasks - overview](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/general-info.md)
- [RavenDB ETL Task](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/ravendb-etl-task.md)
- [OLAP ETL Task](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/olap-etl-task.md)
- [Elasticsearch ETL Task](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/elasticsearch-etl-task.md)
- [Kafka ETL Task](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/kafka-etl-task.md)
- [RabbitMQ ETL Task](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/rabbitmq-etl-task.md)
- [Azure Queue Storage ETL Task](https://docs.ravendb.net/6.2/studio/database/tasks/ongoing-tasks/azure-queue-storage-etl.md)
- [Add](https://docs.ravendb.net/6.2/client-api/operations/maintenance/connection-strings/add-connection-string.md)
- [Get](https://docs.ravendb.net/6.2/client-api/operations/maintenance/connection-strings/get-connection-string.md)
- [Remove](https://docs.ravendb.net/6.2/client-api/operations/maintenance/connection-strings/remove-connection-string.md)
