# Order of columns

**URL:** <https://community.dynatrace.com/t/order-of-columns/39994>\
**Category:** DQL\
**Tags:** dql\
**Created:** [May 31, 2023, 1:38pm UTC](https://community.dynatrace.com/t/order-of-columns/39994 "2023-05-31T13:38:53Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![stefan\_eggersto](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/stefan_eggersto/32/34114_2.png) [@stefan\_eggersto](https://community.dynatrace.com/u/stefan_eggersto)\
**Post date:** [May 31, 2023, 1:38pm UTC](https://community.dynatrace.com/t/order-of-columns/39994/1 "2023-05-31T13:38:53Z")

</div>

Can we set the order of columns?I want following order in the table:

- timestamp
- log.source
- then the column order can be random

---

<div class="post-metadata">

**Author:** ![sinisa\_zubic](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/sinisa_zubic/32/32498_2.png) [@sinisa\_zubic](https://community.dynatrace.com/u/sinisa_zubic)\
**Post date:** [May 31, 2023, 2:07pm UTC](https://community.dynatrace.com/t/order-of-columns/39994/2 "2023-05-31T14:07:31Z")

</div>

Hi Stefan,

the&nbsp;`fields` command can be used to set the order of the fields. Please have a look at the following sample

```markup
fetch logs
| fields timestamp, log.source, content

```

With the fields command you not only specify which fields should be displayed, but also its order. So you need to specify all fields which you want to be visible&nbsp;For further info, please have a look at the documentation of the command:&nbsp;[DQL commands — Dynatrace Docs](https://www.dynatrace.com/support/help/shortlink/dql-commands#fieldsBest),  
Sini
