---
version: "2026.1.0"
language: "en"
---
# Data-Driven

These blocks are used to drive automation cases with external data; whether it comes from web services, spreadsheets, files on disk, or relational databases.

* [**Command‑line**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/command-line.md)**:**Executes operating‑system commands, PowerShell/Bash scripts, and other CLI tools, then captures their standard output and exit code for conditional logic.

* [**Compress File**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/compress-file.md)**:**Zips or unzips files and folders on the fly, allowing you to package test artifacts or extract data sets before they are consumed.

* [Database](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/database.md)**:**Connects through ODBC/JDBC, runs SQL statements, and exposes the result set so each record can drive a test iteration or be validated inside the flow.

* [**HTTP Request**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/http-request.md)**:**Calls any URL with an HTTP/HTTPS request (GET, POST, PUT, DELETE, etc.) and passes the response, status code, headers, and body, on to the next block in the case.

* [**Read Excel**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/read-excel.md)**:**Opens a .xlsx/.xls file, reads row‑by‑row or by range, and feeds each row's values into subsequent blocks as variables.

* [**Save File**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/save-file.md)**:**Writes any text, binary, or image data travelling through the flow to a file whose path and name can be built at runtime.

* [**Send Email**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/send-e-mail.md)**:**Sends SMTP e‑mails directly from a case, with dynamic recipients, subject, body, and attachments.

* [**Set File**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/set-file.md)**:**Injects an existing file, template, media asset, large data set, so later blocks (for example, Send Email or Compress File) can use it without manual uploads.

* [**Write Excel**](https://docs.leapwork.com/leapwork-flow/latest/building-blocks/data-driven/write-excel.md)**:**Creates or updates workbooks during execution, ideal for logging evidence, exporting transformed data, or preparing input files for downstream processes.