> For the complete documentation index, see [llms.txt](https://docs.cloudfabrix.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cloudfabrix.io/rda/rda-userguide/rda-data-management-cfxdm/cfxdm-files-loadfile.md).

# cfxdm - files:loadfile

@**files:loadfile:** It allows users to upload CSV/XLSX/JSON files into AIOps studio for further processing or analysis.

@**files:loadfile:** syntax (parameters)

* **filename**: Mandatory parameter. Enter the filename with path or URL location of the file
* **filetype**: Optional parameter. File type is either csv/json/xlsx. If not specified, it will be derived from the extension.
* **sheet:** Optional parameter. Specify sheet name if the file type is xlsx. If not specified, the first sheet will be returned.

{% hint style="info" %}
The files need to be uploaded to **\~/cfx/cfxdx/home/notebooks** folder from which it can be read and loaded into AIOPs studio using **@files:loadfile** tag.
{% endhint %}

{% hint style="info" %}
Download the [incidents.csv](https://macaw-amer.s3.amazonaws.com/rda/data/incidents.csv) file to the local machine as shown below using a standard web browser. Users can transfer the above dowloaded file to RDA installed machine using standard SFTP/SCP/FTP tools.
{% endhint %}

![CSV file location on the localhost after uload](/files/-MbbTQaj_SKxFScOxMkd)

Once the file is uploaded to RDA machine under above explained location, users can load and perform other operations with 'incidents.csv' file (as explained below).

```
> tag @files:loadfile
@files:loadfile> 
@files:loadfile> data filename = '/root/notebooks/incidents.csv'
```

![RDA will load the file incidents.csv via terminal and displays above UI](/files/-MbbYmkI3-vS8Ep8ZCse)

Below explained tag helps users to save the loaded CSV/XLSX file(s) data into a dataset which can be re-used when needed within the AIOps studio using terminal.

```
@files:loadfile> data filename = '/root/notebooks/incidents.csv' --> @dm:save name = 'incidents-summary'
```

In addition loading CSV files, RDA supports JSON files (format in JSON) as well. Following example shows how to store the above loaded incidents file in CSV format to JSON format.

```
tag *dm:savedlist
*dm:savedlist> data
```

Once users execute the above code using RDA terminal, RDA will print all the stored datasets (including the above stored 'incidents-summary' dataset that was loaded from CSV file.

Once the data is stored in dataset, users can save the dataset into JSON file as shown in the following screenshot.

![Above screenshot displays 'incident-summry' dataset that is stored](/files/-MbbrxWl0A2018LdfKod)

Now run the following code snippet to store the dataset into JSON format.

```
tag @dm:recall
@dm:recall> data name = 'incidents-summary' --> @files:savefile filename = '/root/notebooks/incidents.json'
```

Once a user runs the above snippet, the dataset data is stored in JSON file and stored on the file system as mentioned in the above location (shown in the following screenshot).

![Above screenshot disaplays the file location and the JSON format that was stored ](/files/-MbcLSGhVlin3HHMc2u5)
