# Grafana 7.0.5 - how write manual sql-code in query builder?

**URL:** <https://community.grafana.com/t/grafana-7-0-5-how-write-manual-sql-code-in-query-builder/35810>\
**Category:** Grafana\
**Created:** [August 28, 2020, 9:16am UTC](https://community.grafana.com/t/grafana-7-0-5-how-write-manual-sql-code-in-query-builder/35810 "2020-08-28T09:16:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![johanvroonen](https://avatars.discourse-cdn.com/v4/letter/j/3da27b/32.png) [@johanvroonen](https://community.grafana.com/u/johanvroonen)\
**Post date:** [August 28, 2020, 9:16am UTC](https://community.grafana.com/t/grafana-7-0-5-how-write-manual-sql-code-in-query-builder/35810/1 "2020-08-28T09:16:59Z")

</div>

In grafana 6.7.4 in the query builder is a button “edit sql” for building sql’s manual with sql-code.  
 ![grafana-edit sql button](https://us1.discourse-cdn.com/grafana/original/2X/0/02d24ce28bdca47c27579709aa435fab218a56db.jpeg)

What are the possibilities in grafana 7.0.5 to edit a sql-query manually with sql-code?  
This button below the query window seems to be gone…

 ![grafana-query](https://us1.discourse-cdn.com/grafana/original/2X/f/f44bcd7db21dc50b2fb7dd29d26262f6ffc72bcf.jpeg)

Many thanks

---

<div class="post-metadata">

**Author:** ![agnestoulet1](https://avatars.discourse-cdn.com/v4/letter/a/dec6dc/32.png) [@agnestoulet1](https://community.grafana.com/u/agnestoulet1)\
**Post date:** [August 28, 2020, 12:37pm UTC](https://community.grafana.com/t/grafana-7-0-5-how-write-manual-sql-code-in-query-builder/35810/2 "2020-08-28T12:37:28Z")

</div>

Hello,

The query builder is specific to the data source you are using and you’re not on the same data source on your two screenshots.  
It seems like your second data source doesn’t support writing manual queries.

---

<div class="post-metadata">

**Author:** ![johanvroonen](https://avatars.discourse-cdn.com/v4/letter/j/3da27b/32.png) [@johanvroonen](https://community.grafana.com/u/johanvroonen)\
**Post date:** [August 28, 2020, 1:30pm UTC](https://community.grafana.com/t/grafana-7-0-5-how-write-manual-sql-code-in-query-builder/35810/3 "2020-08-28T13:30:29Z")

</div>

OK… is it difficult to modify the druid datasource to add query builder and if possible also adding alarm treshold values. Where can i find info for doing that ?  
II am experimenting with following iot-stack on my synology NAS server : [https://github.com/iot-experimenter/moquitto-node-red-kafka-druid-grafana](https://github.com/iot-experimenter/moquitto-node-red-kafka-druid-grafana)

Many thanks,  
Regards

---

<div class="post-metadata">

**Author:** ![agnestoulet1](https://avatars.discourse-cdn.com/v4/letter/a/dec6dc/32.png) [@agnestoulet1](https://community.grafana.com/u/agnestoulet1)\
**Post date:** [August 28, 2020, 2:50pm UTC](https://community.grafana.com/t/grafana-7-0-5-how-write-manual-sql-code-in-query-builder/35810/4 "2020-08-28T14:50:20Z")

</div>

The first step would be to check the Github repository of the plugin you are using and, if an issue doesn’t already exist, open one to start discussing this with the plugin maintainers.  
If you want to develop it yourself, the tutorial on [how to build a data source plugin](https://grafana.com/tutorials/build-a-data-source-plugin/#1) for Grafana is a good start to learn more on this topic.
