# Datastreams

A datastream is a structured way to import your data into Marple DB.&#x20;

In the example setup below, there are three datastreams:

1. **Simulation data:** for importing MATLAB files
2. **Heat measurements**: for zipped CSV files
3. **Car data**: for MDF files

<figure><img src="https://3590686807-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwEBNWlmdcxXBXd7oyqyR%2Fuploads%2FIxoE4BujxNLarfwQm6Fr%2Fdatastreams.png?alt=media&#x26;token=4c44d9b1-e96b-4d0a-9f44-834eeddc288f" alt=""><figcaption></figcaption></figure>

Each of these datastreams contains different files, and has a different configuration.

## Importing data

Upload one or multiple files by

* Clicking "Upload Files"
* or by drag and dropping them on the "Upload Files" button

<figure><img src="https://3590686807-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwEBNWlmdcxXBXd7oyqyR%2Fuploads%2FkAQdmMiVhOv74n1G4TFs%2Ffiles.png?alt=media&#x26;token=6e37b998-8028-4958-b589-b90bf53e6e4e" alt=""><figcaption></figcaption></figure>

The import status is shown next to each file.

* <mark style="color:blue;background-color:blue;">**Importing**</mark> means the file is being handled by the plugin. If supported, the plugin will first import priority signals. They will first become available in cold storage and are automatically saved in hot storage as well.
* <mark style="color:red;background-color:red;">**Failed**</mark> means something went wrong. Click the "Failed" to see more details.
* <mark style="color:orange;background-color:yellow;">**Waiting**</mark> means the file is in the queue. By default, two files can be imported in parallel, but this depends on your server configuration.
* <mark style="color:green;background-color:green;">**Imported**</mark> means that all data and metadata is processed

<figure><img src="https://3590686807-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwEBNWlmdcxXBXd7oyqyR%2Fuploads%2FUjnvKRWICZFkUgaRQUnx%2Fimage.png?alt=media&#x26;token=ab376cd2-ee84-4ae8-b13e-fedf023504c1" alt="" width="302"><figcaption></figcaption></figure>

## Metadata

File metadata can be added both manually and automatically.

**Manually**

1. Manually for an individual file

<figure><img src="https://3590686807-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwEBNWlmdcxXBXd7oyqyR%2Fuploads%2FXkzt3glbjrA1V46LmN9G%2Fimage.png?alt=media&#x26;token=c08b12d5-d58e-4719-a256-ac6ff0b57184" alt="" width="375"><figcaption></figcaption></figure>

2. By uploading a `.csv` file, with a column `dataset` and a column for each field you want to set. Example:

```
dataset,Location,Scientist
file1.csv,Italy,James
file2.csv,Spain,Hilde
file3.csv,Germany,Michel
```

{% hint style="warning" %}
Uploading a `.csv` file will overwrite existing metadata values if they were there before.
{% endhint %}

**Automatically**

* From the file upon importing (if the plugin supports it, like [MDF](https://docs.marpledata.com/docs/marple-db/supported-file-types#mdf)).
* Using our [sdk](https://docs.marpledata.com/docs/sdk "mention").
