# How to create a new line on a kibana canvas table

**URL:** <https://discuss.elastic.co/t/how-to-create-a-new-line-on-a-kibana-canvas-table/248179>\
**Category:** Kibana\
**Tags:** canvas\
**Created:** [September 10, 2020, 1:38pm UTC](https://discuss.elastic.co/t/how-to-create-a-new-line-on-a-kibana-canvas-table/248179 "2020-09-10T13:38:09Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![wylie](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wylie/32/81794_2.png) [@wylie](https://discuss.elastic.co/u/wylie)\
**Post date:** [September 14, 2020, 10:31pm UTC](https://discuss.elastic.co/t/how-to-create-a-new-line-on-a-kibana-canvas-table/248179/6 "2020-09-14T22:31:28Z")

</div>

There is no expression function that can insert rows into an existing table. You can insert columns, for example here is a fairly complex table I've made that fetches some number of rows and then calculates the percentage of each row as it relates to the overall total.

 ![Screen Shot 2020-09-14 at 6.30.12 PM](https://us1.discourse-cdn.com/elastic/original/3X/a/e/ae3a9a4926e27eab8c370063bf243b719a79d2bc.png)

It's using the `var_set` and `var` features available in 7.7 and higher:

```auto
filters
| var_set name="results" value={essql query='SELECT DestCityName, COUNT(*) as count from kibana_sample_data_flights group by DestCityName'}
| var name="results"
| var_set name="sum" value={ply expression={math "sum(count)"} | getCell "value"}
| var name="results"
| staticColumn name="sum" value={var name="sum"}
| mapColumn name="percent_of_sum" expression={math "count / sum" | formatnumber "0.0%"}
| sort by="count" reverse=true

```

The alternative to var\_set is copy+pasting queries, but it's not as fast.

---

_[View the full topic](https://discuss.elastic.co/t/how-to-create-a-new-line-on-a-kibana-canvas-table/248179)._
