# append

## Overview

The `append` statement is used to append one [DSET](https://olddocs.exivity.io/2.3.1/getting-started/concepts/datasets) to the end of another.

## Syntax

**`append`***`source_dset.id`***`to`***`destination_dset.id`*

## Details

If the source DSET has any column names not present in the destination DSET then additional columns are automatically created in the destination DSET. These additional columns will contain blank values by default.

If one or more column names are present in both DSETs then the columns copied from the source DSET may be re-ordered into the same order as that used by the destination DSET.

At the end of the operation, the destination DSET will contain all the data from both DSETs, and the source DSET is unchanged.

!!! note Both DSETs must exist and it is not possible to append a DSET to itself

## Example

Given the following DSETs:

DSET ID: *example.data*

```
VMSize,RAM,CPU
small,2,2
medium,4,2
large,8,4
huge,16,8
```

DSET ID: *example2.data*

```
VMSize,storage
small,50
medium,100
large,500
huge,1000
```

The statement `append example2.data to example.data` will result in the following destination DSET (*example.data*):

```
VMSize,RAM,CPU,storage
small,2,2,
medium,4,2,
large,8,4,
huge,16,8,
small,,,50
medium,,,100
large,,,500
huge,,,1000
```
